json---json_encode ----json_decode---eval
1. php 端json编码,js解码
一般在服务器到页面传输数据时,使用jason串传递,需要在php端使用json_encode将json对象编码为json串,然后在页面上得到的数据进行处理前,需要使用eval接收,有json串转回json对象
注意:dataType: "json",ajax中使用 dataType的话,不需要使用eval进行解析,得到是json串
&...
原创
2013-05-23 08:44:15 ·
402 阅读 ·
0 评论