Re: Smarty parsing comment blocks?

From: Date: Tue, 26 Mar 2002 21:32:27 +0000
Subject: Re: Smarty parsing comment blocks?
References: 1 2  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-3377@lists.php.net to get a copy of this message
What version of PHP are you running? On Tue, 26 Mar 2002, Steve Manes wrote: > At 02:33 PM 3/26/2002 -0600, Andrei Zmievski wrote: > >On Tue, 26 Mar 2002, Steve Manes wrote: > >> Mea culpa if this has already been discussed but I just subscribed. Does > >> 2.0.1 fix this > >> comment block problem? I ran into trouble with this: > >> > >> {* here's a comment *} > >> > >> Smarty 2.0 apparently uses an apostrophe as a delimiter in a regexp > >> function. > > > >What problem are you referring to? What error do you get? > > Andrei, > > If I have a single quote (apostrophe) in a comment field like this: > > {* email_status 2: user attempted to create an email that's currently > awaiting validation *} > > I get this: > > ----- > Parse error: parse error in > /mnt/raid/RAID00_5/web/Devel/smanes/Smarty/Smarty-2.0/Smarty_Compiler.class.php(95) > : regexp code on line 2 > > Fatal error: Failed evaluating code: '{*'.str_repeat(" ", > substr_count(' > email_status 2: user attempted to create an email that''s currently > awaiting validation ', " ")) .'*}' in > /mnt/raid/RAID00_5/web/Devel/smanes/Smarty/Smarty-2.0/Smarty_Compiler.class.php > on line 95 > ---- > > It seems from the error message that the parser is using an apostrophe as a > delimiter. -Andrei The Feynman problem solving algorithm: 1) Write down the problem. 2) Think real hard. 3) Write down the answer.

« previous php.smarty.general (#3377) next »