Mantis - Quercus
Viewing Issue Advanced Details
3120 minor always 12-05-08 03:15 02-10-09 05:55
nbzx  
nam  
normal  
closed 3.2.1  
no change required  
none    
none 4.0.0  
0003120: json_encode about some chinese words
example:
<?php
  $str_1 = json_encode('&37319;') . 'a';
  $str_2 = json_encode('&37319;a');
  echo $str_1 == $str2; //It should be 1(ture),but the result is NULL, so some chinese words can't be correctly encode.
?>

Notes
(0003819)
nam   
02-10-09 05:55   
php/470b

Appears to be fixed already on 4.0.

Test case:
=========================================
<?php

var_dump(json_encode("test\xc3\x84"));
var_dump(json_decode("\"test\\u00c4\""));

?>
</php>

Results:
=========================================
string(12) ""test\u00c4""
string(6) "test\xc3\x84"