Code has been added to clipboard!

Code for Encoding PHP

Example
<?php
$myArr = array("Bob", "Bill", "Ben", "Brutus");

$myJSON = json_encode($myArr);

echo $myJSON;
?>