mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-04 10:24:26 +02:00
remove unnecessary close/open tags from compiled templates
This commit is contained in:
2
NEWS
2
NEWS
@@ -1,3 +1,5 @@
|
||||
- remove unnecessary close/open tags from compiled templates
|
||||
(Monte)
|
||||
- fixed errornous creation of '//' in image_path in html_image (messju)
|
||||
- fix escapement of special chars for key vals in debug
|
||||
console (Monte)
|
||||
|
@@ -316,6 +316,9 @@ class Smarty_Compiler extends Smarty {
|
||||
$template_compiled = substr($template_compiled, 0, -1);
|
||||
}
|
||||
|
||||
// remove unnecessary close/open tags
|
||||
$template_compiled = preg_replace('!\?>\n?<\?php!', '', $template_compiled);
|
||||
|
||||
// run compiled template through postfilter functions
|
||||
if (count($this->_plugins['postfilter']) > 0) {
|
||||
foreach ($this->_plugins['postfilter'] as $filter_name => $postfilter) {
|
||||
|
Reference in New Issue
Block a user