|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #22040 PHP hangs when reading certan japaneese or chineese chars
Submitted: 2003-02-04 03:56 UTC Modified: 2003-03-06 07:14 UTC
Avg. Score:4.8 ± 0.4
Reproduced:0 of 0 (0.0%)
From: dan at scannet dot dk Assigned:
Status: Closed Package: Gettext related
PHP Version: 4.3.0 OS: Win2k
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: dan at scannet dot dk
New email:
PHP Version: OS:


 [2003-02-04 03:56 UTC] dan at scannet dot dk
$lang = "ja_JP";
putenv ("LANG=".eregi_replace('.*_','',$lang)); 
setlocale(LC_ALL, "");

bindtextdomain("horde", "C:\Program Files\Apache Group\Apache\web\horde\locale");

echo gettext('Addressbook')    ."\n"; //Returns some japaneese chars..
echo gettext('Delete')         ."\n"; //Returns some japaneese chars..

echo gettext('Birthday') ."\n"; //PHP hangs.. 
echo gettext('Mail')     ."\n"; //PHP hangs.. 
echo gettext('Daily')    ."\n"; //PHP hangs.. 

Birthday: 92 61 30 b6 93 fa
Mail:	  93 64 8e 71 83 81 81 5b 83 8b
Daily:    96 88 93 fa

The only char in common for all 3 is $93
thats #147 in dec..

$test = chr(147);
echo $test;
echo _($test);
// I copy $93 to the $test variable.. Then print $test then print gettext($test)..
// All theese work perfectly, so it seems its not a general problem in php.. 


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-03-04 03:51 UTC]
Which version of apache are you using?

 [2003-03-04 04:12 UTC] dan at scannet dot dk
Hmm... It looks like 1.3.27 according to one of the docs.
this problem also occurs when running PHP.exe from commandline..
 [2003-03-04 04:24 UTC]
Please try using this CVS snapshot:
For Windows:

I cannot reproduce this with the latest snapshot.
All those strings have been displayed correctly on my screen.
 [2003-03-06 07:12 UTC] dan at scannet dot dk
Thank you.. That solved the problem...
 [2003-03-06 07:14 UTC] dan at scannet dot dk
Closing the bug :)
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Jul 13 06:01:30 2024 UTC