summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--it_html.class8
1 files changed, 2 insertions, 6 deletions
diff --git a/it_html.class b/it_html.class
index 35eb273..40fb241 100644
--- a/it_html.class
+++ b/it_html.class
@@ -279,12 +279,8 @@ function _tag($name, $args)
else
$result .= " />$newline";
- if ($GLOBALS['debug_srclines'])
- {
- $trace = debug_backtrace();
- $trace = $trace[2];
- $result = "<!-- " . basename($trace['file']) . ":" . $trace['line'] . " -->" . $result;
- }
+ if ($levels = intval($GLOBALS['debug_srclines']))
+ $result = "<!-- " . it_html::Q(it_debug::backtrace(array('levels' => $levels, 'skipfiles' => "_html\\.class"))) . " -->" . $result; # Hack: Filter it_html and derived classes
return $result;
}