标签:style blog color ar div log sp on
JSON.parse() 用于将 JSON 字符串转换为对象。
var jsontext = ‘{"firstname":"Jesper","surname":"Aaberg","phone":["555-0100","555-0120"]}‘; var contact = JSON.parse(jsontext); document.write(contact.surname + ", " + contact.firstname); // Output: Aaberg, Jesper
标签:style blog color ar div log sp on
原文地址:http://www.cnblogs.com/otfngo/p/3927319.html