summaryrefslogtreecommitdiff
path: root/it_debug.class
diff options
context:
space:
mode:
authorUrban Müller2011-06-10 15:33:15 +0000
committerUrban Müller2011-06-10 15:33:15 +0000
commita5715b0a60991eff22fb5c34f5b3275333949e3d (patch)
tree776f359cecf252dac5cef412b1df5d77444d2285 /it_debug.class
parent464a1482a569cd46e3da0cfadee479669e994c04 (diff)
downloaditools-a5715b0a60991eff22fb5c34f5b3275333949e3d.tar.gz
itools-a5715b0a60991eff22fb5c34f5b3275333949e3d.tar.bz2
itools-a5715b0a60991eff22fb5c34f5b3275333949e3d.zip
link urls
Diffstat (limited to 'it_debug.class')
-rw-r--r--it_debug.class4
1 files changed, 2 insertions, 2 deletions
diff --git a/it_debug.class b/it_debug.class
index b653d22..941576c 100644
--- a/it_debug.class
+++ b/it_debug.class
@@ -145,8 +145,8 @@ function dump($args)
#$item = preg_replace('#\s+var \$_(.|\n)*?;\s*\n#', "", $item);
$item = "$red$item$nored";
- if (isset($_SERVER['REMOTE_ADDR']) && !$plain)
- $item = htmlspecialchars($item);
+ if (isset($_SERVER['REMOTE_ADDR']) && !$plain) # html encode content and link any urls
+ $item = preg_replace("#(http://[^'\"\s]+)#", '<a style="color:red" href="$1">$1</a>', htmlspecialchars($item));
if (preg_match('/^[\'"]/', $var))
$r .= "$item ";