Php / Smarty Help

Php / Smarty Help
I have two arrays that look like:

Array
(
[0] => Array
(
[group] => 19
[name] => Style
)

[1] => Array
(
[group] => 22
[name] => Gender
)

)

Array
(
[0] => Array
(
[0] => Array
(
[name] => Slip On
[code] => 62
)

[1] => Array
(
[name] => Removable Footbed
[code] => 79
)

)

[1] => Array
(
[0] => Array
(
[name] => Men
[code] => 72
)
[1] => Array
(
[name] => Women
[code] => 73
)

)

)

I am trying to get them to output in my smarty template like;

Style
– slip on
– removable footbed

Gender
– Men
– Women

My smarty template code looks like this:

{counter start=0 skip=1 assign=”array_choice2″}
{foreach name=outer item=name from=$productTrackingGroup_name}
<div class=”productOrderBoxSelect”>
<strong>{$array_choice2} – {$name.name}</strong><br />

{foreach item=tracking from=$tracking.$array_choice2}
{$array_choice2} – {$tracking.name}<br />
{/foreach}

For some reason the tracking loop is only showing the style
tracking and not gender. I need someone to help me figure this out promptly.

Leave a Reply

Your email address will not be published. Required fields are marked *