Bugs item #777600, was opened at 2003-07-26 01:06
Message generated for change (Comment added) made by richardarcher
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=403611&aid=777600&group_id=31885
Category: Template
Group: None
>Status: Closed
>Resolution: Rejected
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
>Assigned to: Richard Archer (richardarcher)
Summary: remove undefined variables, removes to much
Initial Comment:
Undefined variables are removed by this line in
template.inc:
$str = preg_replace('/{[^ \t\r\n}]+}/', "", $str);
this removes maybe CSS styles in the template file,
for example:
h1 {color:black}
would be removed or commented:
h1 <!-- Template $handle: Variable color:black
undefined -->
if tryed this, maybe you use it:
$str = preg_replace('/{[^ \t\r\n\:\;}]+}/', "", $str);
so : and ; wouldn't match the regular expression and
CSS or JavaScript Code between {} won't be removed.
----------------------------------------------------------------------
>Comment By: Richard Archer (richardarcher)
Date: 2004-04-21 18:01
Message:
Logged In: YES
user_id=279311
I'm of two minds about this one. But I think that it's best not to
risk breaking existing applications with this change.
There is a very simple work-around... add a space to your style
sheet or javascript. Template variable names cannot contain
spaces or tabs, and there is no reason why they cannot be added
to prevent deletion by template.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=403611&aid=777600&group_id=31885
|