Array $imagelist:
Array (
[additional] => Array (
[count] => 2
[image] => Array (
[nokia_e61_1.jpg] => Array (
[name_body] => nokia_e61_1
[name_ext] => jpg
)
[nokia_e61_2.jpg] => Array (
[name_body] => nokia_e61_2
[name_ext] => jpg
)
[nokia_e61_3.jpg] => Array (
[name_body] => nokia_e61_3
[name_ext] => jpg
)
[nokia_e61_4.jpg] => Array (
[name_body] => nokia_e61_4
[name_ext] => jpg
)
)
)
[main] => nokia_e61
)
The value nokia_e61_1.jpg
is kept in {$getvars.imagename}
.
I wrote {$imagelist.additional.image.`$getvars.imagename`.name_body}
but it doesn't work.
Please help.
see if
{$imagelist.additional.image[$getvars.imagename].name_body}
worksI don't like smarty for this, nevertheless I use it. Here's extract form documentation
To be able to do it, you have to
Hope it helps
Restructure the array, the keys for the inner 'images' offset are redundant anyway:
Gives you numerically indexed images: