SyntaxFix
Write A Post
Hire A Developer
Questions
PHP 5.4 offers the JSON_PRETTY_PRINT option for use with the json_encode() call.
JSON_PRETTY_PRINT
json_encode()
http://php.net/manual/en/function.json-encode.php
<?php ... $json_string = json_encode($data, JSON_PRETTY_PRINT);