php json中国語文字変換
$test0=array(
'id'=>100,
'name'=>"demo ",
);
// ,
foreach($test0 as $key=>$val){
$test[$key]=urlencode($val);
}
$test2=json_encode($test);
$test3=urldecode($test2);
echo $test3;
$test0=array(
'id'=>100,
'name'=>"demo ",
);
// ,
foreach($test0 as $key=>$val){
$test[$key]=urlencode($val);
}
$test2=json_encode($test);
$test3=urldecode($test2);
echo $test3;