From 8e4c3c72db0d7bb6ff4988e7db0b1332a8daef4b Mon Sep 17 00:00:00 2001 From: Etienne Roudeix Date: Mon, 24 Jun 2013 14:44:52 +0200 Subject: [PATCH] prefilter test --- core/lib/Thelia/Core/Template/Smarty/SmartyParser.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/core/lib/Thelia/Core/Template/Smarty/SmartyParser.php b/core/lib/Thelia/Core/Template/Smarty/SmartyParser.php index e85f53284..2f13d60c0 100755 --- a/core/lib/Thelia/Core/Template/Smarty/SmartyParser.php +++ b/core/lib/Thelia/Core/Template/Smarty/SmartyParser.php @@ -62,6 +62,13 @@ class SmartyParser extends Smarty implements ParserInterface { // The default HTTP status $this->status = 200; + + $this->registerFilter("pre", array($this, 'prefunc')); + } + + public function prefunc($tpl_source, \Smarty_Internal_Template $template) + { + exit($tpl_source); } public function setTemplate($template_path_from_template_base) {