diff options
Diffstat (limited to 'it_debug.class')
-rw-r--r-- | it_debug.class | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/it_debug.class b/it_debug.class index 4b0650a..e1766f3 100644 --- a/it_debug.class +++ b/it_debug.class @@ -80,7 +80,7 @@ function srcline($stackoffs = 0) */ function dump($args) { - if (ereg('(csv|txt|gif|jpg)', $_SERVER['PHP_SELF'])) + if (preg_match('/csv|txt|gif|jpg/', $_SERVER['PHP_SELF'])) $plain = 1; else if ($_SERVER['REMOTE_ADDR']) { @@ -136,7 +136,7 @@ function dump($args) { list (, $head, $classname, $values, $tail) = $regs; $classname = strtolower($classname); - $values = preg_replace("#'(\w+)' =>([^\n]+),#", 'var \$$1 = $2;', $values); + $values = preg_replace("#'(\w+)' =>\s*([^\n]+),#", 'var \$$1 = $2;', $values); $item = $head . "class $classname { $values }$tail"; } @@ -151,7 +151,7 @@ function dump($args) if (isset($_SERVER['REMOTE_ADDR']) && !$plain) $item = htmlspecialchars($item); - if (ereg('^[\'"]', $var)) + if (preg_match('/^[\'"]/', $var)) $r .= "$item "; else { $var = "$blue$var=$noblue"; |