Last active
October 3, 2015 07:58
-
-
Save randomecho/2421536 to your computer and use it in GitHub Desktop.
Ugly dump of the variable used, needing something that was easily seen on the page
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
function dump($thevar, $killme = false) | |
{ | |
echo "\n\n".'<pre style="text-align:left;color:#000;background:#fff;padding:1em;border:1px dotted #ccc;margin:1em 0;clear:both;">'."\n\n"; | |
print_r($thevar); | |
if (is_object($thevar)) | |
{ | |
echo "\n\nmethods on this object"; | |
print_r(get_class_methods($thevar)); | |
} | |
echo "</pre>\n\n"; | |
if ($killme) | |
exit(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment