From: werner at aloah-from-hell dot de Operating system: Linux X86_64, Kernel 2.6.32.2 PHP version: 5.2.12 PHP Bug Type: ICONV related Bug description: PHP-CLI 5.2.12 - ICONV broken in CLI
Description: ------------ Hi everybody, we've discovered, that the PHP funktion iconv() does not work with the PHP-CLI in PHP 5.2.12. PHP is configured with the following Options: ./configure --enable-magic-quotes --enable-libxml --enable-session -- with-pcre-regex --with-pear --enable-xml --enable-simplexml --enable- static --enable-safe-mode --enable-sigchild --disable-debug --disable- rpath --enable-cli --enable-bcmath --enable-exif --enable-gd-native- ttf --enable-gd-jis-conv --enable-mbstring --enable-mbreg ex --enable-posix --enable-sockets --with-curl --with-gd=/usr/local -- with-ttf --with-png-dir=/usr --with-jpeg-dir --with-t1lib --with-zlib --with-iconv --with-imap=/usr/lib64 --with-imap-ssl --with-mysql -- with-openssl --with-kerberos --with-xpm-dir --with-freetype-dir=/usr - -with-apxs2=/usr/local/apache2/bin/apxs --disable-cgi --dis able-ipv6 --disable-pdo --without-sqlite --disable-spl --with- mcrypt=/usr --enable-soap ICONV-Support ist active: server:# php -r 'phpinfo();'|grep -i iconv ... iconv iconv support => enabled iconv implementation => glibc iconv library version => 2.3.6 iconv.input_encoding => ISO-8859-1 => ISO-8859-1 iconv.internal_encoding => ISO-8859-1 => ISO-8859-1 iconv.output_encoding => ISO-8859-1 => ISO-8859-1 Kind regards, Werner Reproduce code: --------------- <?php $text = "abcde"; echo iconv('UTF-8', 'ISO-8859-1', $text), PHP_EOL; ?> Expected result: ---------------- With PHP 5.2.11: server:# /usr/local/bin/php /tmp/test.php abcde server:# Actual result: -------------- With PHP 5.2.12: server:# /usr/local/bin/php /tmp/test.php server:# -- Edit bug report at http://bugs.php.net/?id=50746&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=50746&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=50746&r=trysnapshot53 Try a snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=50746&r=trysnapshot60 Fixed in SVN: http://bugs.php.net/fix.php?id=50746&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=50746&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=50746&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=50746&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=50746&r=needscript Try newer version: http://bugs.php.net/fix.php?id=50746&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=50746&r=support Expected behavior: http://bugs.php.net/fix.php?id=50746&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=50746&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=50746&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=50746&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=50746&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=50746&r=dst IIS Stability: http://bugs.php.net/fix.php?id=50746&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=50746&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=50746&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=50746&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=50746&r=mysqlcfg