2024 年 11 月
 123
45678910
11121314151617
18192021222324
252627282930  

近期发布

近期评论

    2024 年 11 月 5 日

    Neusofts

    科技改变生活,创新引领未来

    json3

    JSON 3 is a modern JSON implementation compatible with a variety of JavaScript platforms, including Internet Explorer 6, Opera 7, Safari 2, and Netscape 6.

    Website:http://bestiejs.github.com/json3

    Example:

    Code:

    var r = document.getElementById('results')
    r.innerHTML = JSON.stringify({"Hello": 123});
    r.innerHTML+='<br />'
    
    JSON.parse("[[1, 2], 1, 2]", function (key, value) {
      if (typeof value == "number") {
        value = value % 2 ? "Odd" : "Even";
        value += '<br />';
      }
      r.innerHTML+= value;
    });

    Result:

    {“Hello”:123}
    Even
    Odd
    Even
    Odd
    ,,,