Re: [SMARTY] Simple variable/array/assign-problem? Associative array using a variable to point

From: Date: Thu, 17 Oct 2002 14:34:15 +0000
Subject: Re: [SMARTY] Simple variable/array/assign-problem? Associative array using a variable to point
References: 1 2  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-6186@lists.php.net to get a copy of this message
Hi. I made a plugin for it. Works well now, thank you. Cheers. Johannes ----- Original Message ----- From: "Johannes Schill" <johannes.schill@polyester.se> To: <smarty-general@lists.php.net> Sent: Thursday, October 17, 2002 3:28 PM Subject: [SMARTY] Simple variable/array/assign-problem? Associative array using a variable to point > Hello again, > > My problem this time: > > This works: > {assign var="tmp" value=$silverData[258]} > > But this doesnt work: > {assign var="offer_id" value=258} > {assign var="tmp" value=$silverData[$offer_id]} > > I need to dynamically (using an variable, $offer_id), point to a post in an > array ($silverData). Is there a workaround? > > Best regards, > Johannes Schill > > > > -- > Smarty General Mailing List (http://smarty.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > >

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