diff options
Diffstat (limited to 'it_debug.class')
-rw-r--r-- | it_debug.class | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/it_debug.class b/it_debug.class index eacdeb1..b7df95b 100644 --- a/it_debug.class +++ b/it_debug.class @@ -81,7 +81,7 @@ static function dump($args) if ((preg_match('/csv|txt|gif|jpg/', $_SERVER['PHP_SELF']) || preg_grep('#text/(calendar|css|javascript|json|plain|rfc822|xml)|application/#', headers_list()) || $GLOBALS['debug_edplain']) && !$GLOBALS['debug_edhtml']) $plain = 1; else if ($_SERVER['REMOTE_ADDR']) - list($blue, $noblue) = array("<span style='color:#00c'>", "</span>"); + list($blue, $noblue, $htmlok) = array("<span style='color:#00c'>", "</span>", 1); else if (posix_isatty(STDOUT)) list($blue, $noblue, $red, $nored) = getenv('IT_ED_BRIGHT') ? array("\033[34m", "\033[m", "\033[33m", "\033[m") : array("\033[34m", "\033[m", "\033[31m", "\033[m"); @@ -143,7 +143,7 @@ static function dump($args) if (isset($_SERVER['REMOTE_ADDR']) && !$plain) # html encode content and link any urls $item = htmlspecialchars($item, ENT_COMPAT, "ISO-8859-1"); - if (!$plain) + if ($htmlok) $item = preg_replace("#http://[^ ']*#", "<a href='\$0'>\$0</a>", $item); if (preg_match('/^[\'"]/', $var)) |