JSON, which stands for "Javascript object notation", is a lightweight data interchange format.
JSON and Javascript
Unlike many Object-oriented programming languages, Javascript objects do not necessarily have to be created by a constructor. Javascript objects can be created by an object literal format. For example:
my_object = { "name" : "Joe Blow" , "address" : "123 Somewhere Street" , "city" : "Surrey" , "province" : "BC" , "country" : "Canada" };
This produces a Javascript object named "my_object" with fields: "name", "address", "city", "province", and "country". One could use this object as follows:
document.write("My name is "+my_object.name+".\n"); document.write("And I live on "+my_object.address+" in "+my_object.city+".\n");
Which would print out:
My name is Joe Blow. And I live on 123 Somewhere Street in Surrey.
JSON is a Javascript object literal.
JSON Pronunciation
JSON is pronounced like the name "Jason".