I\'ve looked on wikipedia and Googled it and read the official documentation, but I still haven\'t got to the point where I really understand what JSON is, and why I\'d use
What is JSON?
JavaScript Object Notation (JSON) is a lightweight data-interchange format inspired by the object literals of JavaScript.
JSON values can consist of:
objects (collections of name-value pairs) arrays (ordered lists of values) strings (in double quotes) numbers true, false, or null
JSON is language independent.
JSON with PHP?
After PHP Version 5.2.0, JSON extension is decodes and encodes functionalities as default.
Json_encode - returns the JSON representation of values Json_decode - Decodes the JSON String Json_last_error - Returns the last error occured.
JSON Syntax and Rules?
JSON syntax is derived from JavaScript object notation syntax:
Data is in name/value pairs Data is separated by commas Curly braces hold objects Square brackets hold arrays