<script> var o={}; o.name="jahid"; o.age="30"; var arr=[]; arr.push(o); o={}; o.name="Jone"; o.age="50"; arr.push(o); arr.push({'name':'Ridon','age':'34'}); arr.push({'name':'Asha','age':'28'}); alert(arr[0].name); alert(arr[1].name); alert(arr[2].name); alert(arr[3].name); </script>
var json = '{"cool":"34.33","alsocool":"45454"}'; // is JSON var o = JSON.parse(json); // is a javscript object json = JSON.stringify; // is JSON again
Comments 1