mirror of
https://github.com/smarty-php/smarty.git
synced 2025-08-04 18:34:27 +02:00
fix bug in new comment logic
This commit is contained in:
@@ -240,9 +240,11 @@ class Smarty_Compiler extends Smarty {
|
||||
/* Annihilate the comments. */
|
||||
|
||||
$_comment_search = array(
|
||||
"!(\r|\r\n|\n)({$ldq})\*(.*?)\*({$rdq})(\r|\r\n|\n)!s",
|
||||
"!({$ldq})\*(.*?)\*({$rdq})!s");
|
||||
"!{$ldq}\*.*?\*{$rdq}!s", // get all onto one line
|
||||
"!(\r|\r\n|\n)%%%SMARTY_COMMENT%%%(\r|\r\n|\n)!", // remove CR if on one line
|
||||
'!%%%SMARTY_COMMENT%%%!'); // remove remaining comments
|
||||
$_comment_replace = array(
|
||||
'%%%SMARTY_COMMENT%%%',
|
||||
'\\1',
|
||||
'');
|
||||
|
||||
|
Reference in New Issue
Block a user