Skip to content

Instantly share code, notes, and snippets.

@Motoma
Created September 21, 2010 18:03
Show Gist options
  • Save Motoma/590148 to your computer and use it in GitHub Desktop.
Save Motoma/590148 to your computer and use it in GitHub Desktop.
<?php
$DEBUGGING = True;
$TRACECOUNT = 0;
if($DEBUGGING)
{
error_reporting(E_ALL);
ini_set('display_errors', True);
)
function trace($message)
global $DEBUGGING;
global $TRACECOUNT;
if($DEBUGGING)
{
echo '<hr />;'.$TRACECOUNT++.'<code>'.$message.'</code><hr />';
}
}
function tarr($arr)
{
global $DEBUGGING;
global $TRACECOUNT;
if($DEBUGGING)
{
echo '<hr />'.$TRACECOUNT++.'<code>';
print_r($arr);
echo '</code><hr />';
}
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment