Re: [SMARTY] Smarty error on PHP include

From: Date: Thu, 21 Nov 2002 12:42:40 +0000
Subject: Re: [SMARTY] Smarty error on PHP include
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-6488@lists.php.net to get a copy of this message
On Thu, Nov 21, 2002 at 01:35:26PM +0100, Sonny2@gmx.de wrote: > Fatal error: Smarty: [in search_casedata.tpl line 25]: syntax error: invalid > attribute name - '"$row[account_name]";' in > /www-1/src/php/lib/php/Smarty_Compiler.class.php on line 1398 > echo "<option > > value=\"".$row['account_code']."\">$row['account_name']</option>\n"; This is incorrect. Use {} or place variable outside the quotes: value=\"".$row['account_code']."\">${row['account_name']}</option>\n"; value=\"".$row['account_code']."\">".$row['account_name']."</option>\n" -- Piotr Klaban

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