Re: [SMARTY] finding array members
| From: | boots | Date: | Thu, 06 Apr 2006 13:46:18 +0000 |
| Subject: | Re: [SMARTY] finding array members | ||
| References: | 1 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-13388@lists.php.net to get a copy of this message | ||
Well, one simple way is to use php's array_keys as a modifier:
eg:
{assign var=keys value=$record|array_keys}
xo boots
--- D_C <lister@pikkle.com> wrote:
> i am working on a smarty template with some passed in arrays from
> another programmer.
>
> is there a way in smarty of walking through the array to find out the
> index names etc?
>
> eg in the .tpl
>
> {$array[0].key}
>
> or
>
> {foreach item=fitem key=fkey from=$titem}
> {$fkey}
>
> thanks!
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com