Created
August 8, 2015 19:57
-
-
Save iammilton82/1b50771c9d9d2cffa050 to your computer and use it in GitHub Desktop.
Print array and console
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function printIt($data){ | |
echo "<pre>"; | |
print_r($data); | |
echo "</pre>"; | |
} | |
public function console($data){ | |
$data = json_encode($data); | |
echo "<script type='text/javascript'>console.log($data)</script>"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment