fixed handling of strip-tags with non-default delimiters

This commit is contained in:
messju
2005-02-09 14:31:18 +00:00
parent 5c27123e8f
commit 468ec392ee
2 changed files with 4 additions and 2 deletions

2
NEWS
View File

@@ -1,3 +1,5 @@
- fix handling of strip-tags with non-default delimiters (Mark West, messju)
Version 2.6.7 (Feb 3, 2005) Version 2.6.7 (Feb 3, 2005)
--------------------------- ---------------------------

View File

@@ -529,13 +529,13 @@ class Smarty_Compiler extends Smarty {
$this->_pop_tag('strip'); $this->_pop_tag('strip');
if (--$this->_strip_depth==0) { /* outermost closing {/strip} */ if (--$this->_strip_depth==0) { /* outermost closing {/strip} */
$this->_additional_newline = "\n"; $this->_additional_newline = "\n";
return $this->left_delimiter.$tag_command.$this->right_delimiter; return '{' . $tag_command . '}';
} }
} else { } else {
$this->_push_tag('strip'); $this->_push_tag('strip');
if ($this->_strip_depth++==0) { /* outermost opening {strip} */ if ($this->_strip_depth++==0) { /* outermost opening {strip} */
$this->_additional_newline = ""; $this->_additional_newline = "";
return $this->left_delimiter.$tag_command.$this->right_delimiter; return '{' . $tag_command . '}';
} }
} }
return ''; return '';