document.write('<div class="php" style="font-family: monospace;"><br />');
document.write('<span style="color: #000000; font-weight: bold;">&lt;?php</span> <br />');
document.write('<span style="color: #808080; font-style: italic;">/**<br />');
document.write('&nbsp;* Simple Debug Function<br />');
document.write('&nbsp;*<br />');
document.write('&nbsp;* @param mixed $var<br />');
document.write('&nbsp;* @param boolean $visible<br />');
document.write('&nbsp;* @param boolean $return<br />');
document.write('&nbsp;* @return mixed<br />');
document.write('&nbsp;*/</span><br />');
document.write('<span style="color: #000000; font-weight: bold;">function</span> varDebug<span style="color: #66cc66;">&#40;</span>&amp;<span style="color: #0000ff;">$var</span>, <span style="color: #0000ff;">$visible</span> = <span style="color: #000000; font-weight: bold;">true</span>, <span style="color: #0000ff;">$return</span> = <span style="color: #000000; font-weight: bold;">false</span><span style="color: #66cc66;">&#41;</span><br />');
document.write('<span style="color: #66cc66;">&#123;</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">$containers</span> = <a target="_blank"&nbsp; href="http://www.php.net/array"><span style="color: #000066;">array</span></a><span style="color: #66cc66;">&#40;</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #808080; font-style: italic;">// $visible == false</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #cc66cc;">0</span> =&gt; <a target="_blank"&nbsp; href="http://www.php.net/array"><span style="color: #000066;">array</span></a><span style="color: #66cc66;">&#40;</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">\'head\'</span> =&gt; <span style="color: #ff0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&lt;!--<span style="color: #000099; font-weight: bold;">\n</span><span style="color: #000099; font-weight: bold;">\n</span>DEBUG:<span style="color: #000099; font-weight: bold;">\n</span>---------------------------------------<span style="color: #000099; font-weight: bold;">\n</span><span style="color: #000099; font-weight: bold;">\n</span>&quot;</span>,<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">\'foot\'</span> =&gt; <span style="color: #ff0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span><span style="color: #000099; font-weight: bold;">\n</span>---------------------------------------<span style="color: #000099; font-weight: bold;">\n</span><span style="color: #000099; font-weight: bold;">\n</span>--&gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#41;</span>,<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #808080; font-style: italic;">// $visible == true</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #cc66cc;">1</span> =&gt; <a target="_blank"&nbsp; href="http://www.php.net/array"><span style="color: #000066;">array</span></a><span style="color: #66cc66;">&#40;</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">\'head\'</span> =&gt; <span style="color: #ff0000;">\'&lt;hr /&gt;&lt;h1&gt;Debug&lt;/h1&gt;&lt;p&gt;\'</span>,<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #ff0000;">\'foot\'</span> =&gt; <span style="color: #ff0000;">\'&lt;/p&gt;&lt;hr /&gt;\'</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#41;</span><br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #66cc66;">&#41;</span>;<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">$r</span> = <a target="_blank"&nbsp; href="http://www.php.net/var_export"><span style="color: #000066;">var_export</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$var</span>, <span style="color: #000000; font-weight: bold;">true</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$visible</span><span style="color: #66cc66;">&#41;</span> <span style="color: #0000ff;">$r</span> = <a target="_blank"&nbsp; href="http://www.php.net/str_replace"><span style="color: #000066;">str_replace</span></a><span style="color: #66cc66;">&#40;</span><a target="_blank"&nbsp; href="http://www.php.net/array"><span style="color: #000066;">array</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">\' \'</span>, <span style="color: #ff0000;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #66cc66;">&#41;</span>, <a target="_blank"&nbsp; href="http://www.php.net/array"><span style="color: #000066;">array</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">\' \'</span>, <span style="color: #ff0000;">&quot;&lt;br /&gt;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #66cc66;">&#41;</span>, <span style="color: #0000ff;">$r</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">$container</span> = <a target="_blank"&nbsp; href="http://www.php.net/intval"><span style="color: #000066;">intval</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$visible</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000ff;">$r</span> = <span style="color: #0000ff;">$containers</span><span style="color: #66cc66;">&#91;</span><span style="color: #0000ff;">$container</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">\'head\'</span><span style="color: #66cc66;">&#93;</span> . <span style="color: #0000ff;">$r</span> . <span style="color: #0000ff;">$containers</span><span style="color: #66cc66;">&#91;</span><span style="color: #0000ff;">$container</span><span style="color: #66cc66;">&#93;</span><span style="color: #66cc66;">&#91;</span><span style="color: #ff0000;">\'foot\'</span><span style="color: #66cc66;">&#93;</span>;<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">if</span> <span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$return</span><span style="color: #66cc66;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #0000ff;">$r</span>;<br />');
document.write('&nbsp; &nbsp; &nbsp; &nbsp; <a target="_blank"&nbsp; href="http://www.php.net/echo"><span style="color: #000066;">echo</span></a> <span style="color: #0000ff;">$r</span>;<br />');
document.write('<span style="color: #66cc66;">&#125;</span><br />');
document.write('<br />');
document.write('<span style="color: #808080; font-style: italic;">/**<br />');
document.write('&nbsp;* EXAMPLES:<br />');
document.write('&nbsp;*/</span><br />');
document.write('<br />');
document.write('<span style="color: #0000ff;">$a</span> = <a target="_blank"&nbsp; href="http://www.php.net/array"><span style="color: #000066;">array</span></a><span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">\'h\'</span> =&gt; <span style="color: #cc66cc;">1</span>, <span style="color: #ff0000;">\'e\'</span> =&gt; <span style="color: #cc66cc;">2</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('<br />');
document.write('varDebug<span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$a</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('<br />');
document.write('<span style="color: #808080; font-style: italic;">/*<br />');
document.write('OUTPUTS:<br />');
document.write('&lt;hr /&gt;&lt;h1&gt;Debug&lt;/h1&gt;&lt;p&gt;array (&lt;br /&gt;<br />');
document.write('&nbsp; \'h\' =&gt; 1,&lt;br /&gt;<br />');
document.write('&nbsp; \'e\' =&gt; 2,&lt;br /&gt;<br />');
document.write(')&lt;/p&gt;&lt;hr /&gt;<br />');
document.write('*/</span><br />');
document.write('<br />');
document.write('varDebug<span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$a</span>, <span style="color: #000000; font-weight: bold;">false</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('<br />');
document.write('<span style="color: #808080; font-style: italic;">/*<br />');
document.write('OUTPUTS:<br />');
document.write('&lt;!--<br />');
document.write('<br />');
document.write('DEBUG:<br />');
document.write('---------------------------------------<br />');
document.write('<br />');
document.write('array (<br />');
document.write('&nbsp; \'h\' =&gt; 1,<br />');
document.write('&nbsp; \'e\' =&gt; 2,<br />');
document.write(')<br />');
document.write('<br />');
document.write('---------------------------------------<br />');
document.write('<br />');
document.write('--&gt;<br />');
document.write('*/</span><br />');
document.write('<br />');
document.write('varDebug<span style="color: #66cc66;">&#40;</span><span style="color: #0000ff;">$a</span>, <span style="color: #000000; font-weight: bold;">false</span>, <span style="color: #000000; font-weight: bold;">true</span><span style="color: #66cc66;">&#41;</span>;<br />');
document.write('<br />');
document.write('<span style="color: #808080; font-style: italic;">/*<br />');
document.write('OUTPUTS nothing<br />');
document.write('*/</span><br />');
document.write('<span style="color: #000000; font-weight: bold;">?&gt;</span><br />');
document.write('&nbsp;</div>');
document.write('<br />&nbsp;<br /><div style="font-size: 12px">Brought to you by the community at <a href="http://www.bytemycode.com/snippets/snippet/441/1/" target="_blank">byteMyCode</a>.</div>');
