object in JSON? code example
Example 1: json object
var myObj, x;
myObj = {"name":"John", "age":30, "car":null};
x = myObj.name;
document.getElementById("demo").innerHTML = x;
Example 2: json objects
{ "name":"John", "age":30, "car":null }
var myObj, x;
myObj = {"name":"John", "age":30, "car":null};
x = myObj.name;
document.getElementById("demo").innerHTML = x;
{ "name":"John", "age":30, "car":null }