- remove exception_handler property from Smarty class

- added Smarty's own exceptions SmartyException and SmartyCompilerException
This commit is contained in:
Uwe.Tews
2010-08-13 10:39:51 +00:00
parent cbc4205669
commit ad921936b0
17 changed files with 68 additions and 66 deletions

View File

@@ -102,10 +102,10 @@ class Smarty_Internal_Resource_PHP {
public function renderUncompiled($_smarty_template)
{
if (!$this->smarty->allow_php_templates) {
throw new Exception("PHP templates are disabled");
throw new SmartyException("PHP templates are disabled");
}
if ($this->getTemplateFilepath($_smarty_template) === false) {
throw new Exception("Unable to load template \"{$_smarty_template->resource_type} : {$_smarty_template->resource_name}\"");
throw new SmartyException("Unable to load template \"{$_smarty_template->resource_type} : {$_smarty_template->resource_name}\"");
}
// prepare variables
$_smarty_ptr = $_smarty_template;
@@ -124,4 +124,4 @@ class Smarty_Internal_Resource_PHP {
}
}
?>
?>