fix problem with debug_tpl path and security

This commit is contained in:
mohrt
2004-03-30 15:51:27 +00:00
parent 1db754e93a
commit 9177ccb406

View File

@@ -21,10 +21,11 @@ function smarty_core_display_debug_console($params, &$smarty)
if(empty($smarty->debug_tpl)) {
// set path to debug template from SMARTY_DIR
$smarty->debug_tpl = 'file:' . SMARTY_DIR . 'debug.tpl';
$smarty->debug_tpl = SMARTY_DIR . 'debug.tpl';
if($smarty->security && is_file($smarty->debug_tpl)) {
$smarty->secure_dir[] = dirname(realpath($smarty->debug_tpl));
}
$smarty->debug_tpl = 'file:' . SMARTY_DIR . 'debug.tpl';
}
$_ldelim_orig = $smarty->left_delimiter;