Home > Article > Backend Development > json_encode()函数为啥不能解析带中文的JSON字符串呢
json_encode()函数为什么不能解析带中文的JSON字符串呢?
这样就有值:
<br /> $a = '{ "a":"www", "b":2}';<br /> $arr = json_decode($a, true);<br />
<br /> $a = '{ "a":"你好", "b":2}';<br /> $arr = json_decode($a, true);<br />