From 1153ea5a5a1197ff41b572516426d5d7836904fd Mon Sep 17 00:00:00 2001 From: "uwe.tews@googlemail.com" Date: Mon, 22 Nov 2010 19:43:11 +0000 Subject: [PATCH] - bugfix on template inheritance when an {extends} tag was inserted by a prefilter --- change_log.txt | 3 +++ libs/sysplugins/smarty_internal_templatecompilerbase.php | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/change_log.txt b/change_log.txt index a39d582b..0f5f3794 100644 --- a/change_log.txt +++ b/change_log.txt @@ -1,3 +1,6 @@ +22/11/2010 +- bugfix on template inheritance when an {extends} tag was inserted by a prefilter + ===== Smarty 3.0.5 ===== diff --git a/libs/sysplugins/smarty_internal_templatecompilerbase.php b/libs/sysplugins/smarty_internal_templatecompilerbase.php index ffa7955e..0470ec4c 100644 --- a/libs/sysplugins/smarty_internal_templatecompilerbase.php +++ b/libs/sysplugins/smarty_internal_templatecompilerbase.php @@ -67,7 +67,7 @@ class Smarty_Internal_TemplateCompilerBase { $_content = $template->getTemplateSource(); // run prefilter if required if (isset($this->smarty->autoload_filters['pre']) || isset($this->smarty->registered_filters['pre'])) { - $_content = Smarty_Internal_Filter_Handler::runFilter('pre', $_content, $template); + $template->template_source = $_content = Smarty_Internal_Filter_Handler::runFilter('pre', $_content, $template); } // on empty template just return header if ($_content == '') {