Re: [SMARTY] Problem with JavaScript in templates

From: Date: Thu, 31 Oct 2002 11:03:39 +0000
Subject: Re: [SMARTY] Problem with JavaScript in templates
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-6284@lists.php.net to get a copy of this message
{literal} <script language=\"javaScript\"> <!-- function closeWin() { var closeWin=window.self.close(); } // --> </script> {/literal} --------------- Sincerely, Eskil Kvalnes eskil@uten.net ----- Original Message ----- From: "Geranium" <vlcc69jfbo001@sneakemail.com> To: <smarty-general@lists.php.net> Sent: Thursday, October 31, 2002 11:53 AM Subject: [SMARTY] Problem with JavaScript in templates > I have some Javascript in my template like this: > > <script language=\"javaScript\"> > <!-- > function closeWin() { > var closeWin=window.self.close(); > } > // --> > </script> > > When parsing the template that contains this, Smarty dies with a fatal > error: > > Fatal error: Smarty plugin error: [in string template line 7]: unknown > tag - 'var' in /var/www/php/includes/Smarty.class.php on line 1980 > > It looks like the curly brackets used by JavaScript are confusing > Smarty into interpreting JavaScript as Smarty tags. > > How can I prevent this? > > -- > Smarty General Mailing List (http://smarty.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > >

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