Re: [SMARTY] accessing array from within section loop
| From: | Jason Sweat | Date: | Tue, 06 May 2003 02:14:22 +0000 |
| Subject: | Re: [SMARTY] accessing array from within section loop | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-9478@lists.php.net to get a copy of this message | ||
Shouldn't that be
{assign var="status" value=$array1[count].value1}
not
{assign var="status" value=$array1[cont].value1}
base on what you named the section
----- Original Message -----
From: "Robert Mena" <rt_mena@yahoo.com>
To: <smarty-general@lists.php.net>
Sent: Monday, May 05, 2003 10:57 AM
Subject: [SMARTY] accessing array from within section loop
> Hi,
>
> I am beginning to use smarty and found one problem.
>
> I need to access an array using a value obtained from
> another array, which is looped in a section.
>
> For ex.
> {section name=count loop=$array1}
>
> {assign var="status" value=$array1[cont].value1}
> {$array2[$status]}
> {/section}
>
> Both array1 and 2 have been assigned.
>
> Regards,
>
> __________________________________
> Do you Yahoo!?
> The New Yahoo! Search - Faster. Easier. Bingo.
> http://search.yahoo.com
>
> --
> Smarty General Mailing List (http://smarty.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>