<script>
alert("test");
var test={};
test.count=3;
alert(test.count);
test.data=[];
test.data[0]=1;
test.data[1]=2;
alert(test.data[0]+","+test.data[1]);
var toStr = JSON.stringify(test);
alert(toStr);
document.write(toStr);
</script>
{"count":3,"data":[1,2]}
原文链接:https://www.f2er.com/json/289687.html