From: Operating system: Windows PHP version: 5.3.6 Package: *General Issues Bug Type: Bug Bug description:echo,proc_open,... issues with UTF-8 terminal
Description: ------------ Those functions (at least) do strange things when using an UTF-8 terminal under Windows. For instance, doing a php 'echo' on a UTF-8 string does not output the string! Printing the same string with fwrite(STDOUT,$string) works. More problematic : parsing UTF-8 data and trying to execute a program (I've tried popen,exec,proc_open,passthru) with those data as program arguments make the program to not understand the decoding that should be used. Writing the script output to a batch file and executing the batch works. Test script: --------------- Launch a cmd.exe. Execute chcp 65001 to get the terminal use UTF-8 (make sure your font support this, use Lucida console for instance). Launch this script : <?php $data="ï"; fwrite(STDOUT,$data."\n"); echo $data."\n"; ?> Expected result: ---------------- I'm expecting UTF-8 data to be shown correctly and program execution string passed to exec() and so use correct string decoding. Actual result: -------------- ï �� -- Edit bug report at http://bugs.php.net/bug.php?id=54569&edit=1 -- Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=54569&r=trysnapshot52 Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=54569&r=trysnapshot53 Try a snapshot (trunk): http://bugs.php.net/fix.php?id=54569&r=trysnapshottrunk Fixed in SVN: http://bugs.php.net/fix.php?id=54569&r=fixed Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=54569&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=54569&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=54569&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=54569&r=needscript Try newer version: http://bugs.php.net/fix.php?id=54569&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=54569&r=support Expected behavior: http://bugs.php.net/fix.php?id=54569&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=54569&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=54569&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=54569&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=54569&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=54569&r=dst IIS Stability: http://bugs.php.net/fix.php?id=54569&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=54569&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=54569&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=54569&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=54569&r=mysqlcfg
