Category Archives: Json

Json – JavaScript Object Notation

Output Ajax JSON Header in PHP

Overview of JSON JSON is an acronym for JavaScript Object Notation. It is essentially a way of exchanging data between a source and destination using name/value pairs. Commonly used when transferring data from a database to a website using AJAX. Generating a JSON object using php is pretty simple (although it won’t be covered [...]

Pass a PHP Array to Javascript as JSON using AJAX and json_encode

Overview You will mostly likely (or already have) reached a point where you have a PHP array and you need to be able to access that array from inside a Javascript function. You may wonder if it is possible to pass an array from PHP to Javascript. Fortunately I have created a tutorial on how [...]