RE: SV: [SMARTY] $smarty.post.myArray[index] in cvs

From: Date: Fri, 21 Mar 2003 15:51:19 +0000
Subject: RE: SV: [SMARTY] $smarty.post.myArray[index] in cvs
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-8811@lists.php.net to get a copy of this message
> > smarty (up to 2.4.2. I believe) allowed to loop through a > $_POST array with > > a section like: > > > > {section name=index loop=$smarty.post.posted_vars} > > {$smarty.post.posted_vars[index]} > > {/section} > > > > posted_vars are posted by means of: > > <input type ="hidden" name="posted_vars[]" > > value="value1"> > > <input type ="hidden" name="posted_vars[]" > > value="value2"> > > and so on > > > > With smarty 2.5.0 RC1 I get an error: > > syntax error: $smarty.post.posted_vars is an invalid reference > > (Smarty_Compiler.class.php, line 1681) in > > c:\php\pear\Smarty\Smarty_Compiler.class.php on line 1812 > > I am also getting error in smarty 2.5.0 RC1 when i attempted to do something like this.. {if !$smarty.session.cart->inCart($seller_id,$item_id)} If i remember right it was the same error. Rob Schultz

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