XF 1.5 How to set a variable to array values in template

sajal

Active member
I've made a helper that returns an array:

{xen:helper product_options, $tags}

Now, I want to go through this options and prepare select box. Seems that following syntax is not working.

<xen:foreach loop="{xen:helper product_options, $tags}" value="$option">
....
</xen:foreach>

Also, I tried to initialize that array to some other variable that's not working too.

<xen:set var="$tempVar">{xen:helper product_options, $tags}</xen:set>

It sets $tempVar to string "Array" instead of actual array values.

Any ideas?
 
Back
Top Bottom