mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-05 19:04:27 +02:00
- bugfix escape and wordrap modifier could be compiled into wrong code when used in {nocache}{/nocache}
section but caching is disabled (Forum Topic 24260)
This commit is contained in:
@@ -1,4 +1,8 @@
|
||||
===== trunk =====
|
||||
25.04.2013
|
||||
- bugfix escape and wordrap modifier could be compiled into wrong code when used in {nocache}{/nocache}
|
||||
section but caching is disabled (Forum Topic 24260)
|
||||
|
||||
05.04.2013
|
||||
- bugfix post filter must not run when compiling inheritance child blocks (Forum Topic 24094)
|
||||
- bugfix after the fix for Issue #130 compiler exceptions got double escaped (Forum Topic 24199)
|
||||
|
@@ -112,7 +112,7 @@ function smarty_modifiercompiler_escape($params, $compiler)
|
||||
}
|
||||
|
||||
// could not optimize |escape call, so fallback to regular plugin
|
||||
if ($compiler->tag_nocache | $compiler->nocache) {
|
||||
if ($compiler->template->caching && ($compiler->tag_nocache | $compiler->nocache)) {
|
||||
$compiler->template->required_plugins['nocache']['escape']['modifier']['file'] = SMARTY_PLUGINS_DIR .'modifier.escape.php';
|
||||
$compiler->template->required_plugins['nocache']['escape']['modifier']['function'] = 'smarty_modifier_escape';
|
||||
} else {
|
||||
|
@@ -31,7 +31,7 @@ function smarty_modifiercompiler_wordwrap($params, $compiler)
|
||||
}
|
||||
$function = 'wordwrap';
|
||||
if (Smarty::$_MBSTRING) {
|
||||
if ($compiler->tag_nocache | $compiler->nocache) {
|
||||
if ($compiler->template->caching && ($compiler->tag_nocache | $compiler->nocache)) {
|
||||
$compiler->template->required_plugins['nocache']['wordwrap']['modifier']['file'] = SMARTY_PLUGINS_DIR .'shared.mb_wordwrap.php';
|
||||
$compiler->template->required_plugins['nocache']['wordwrap']['modifier']['function'] = 'smarty_mb_wordwrap';
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user