Share » Forums » Setup & design » Working with data in a Loop

Working with data in a Loop

Working with data in a Loop

Monday 27 October 2003 1:40:08 am - 2 replies

Author Message

Vivienne van Velzen

Monday 27 October 2003 3:46:38 am

Hi Matt,

Couldn't you do something like this:

{let name=myroot
     mytext=""
}
{section loop=fetch...}
    {section show=$myroot:mytext|ne($:item.attribute)}
        ----------<br>
    {/section}
    {$:item.data_map.country.data_text}<br>
    {set mytext=$:item.attribute}
{/section}
{/let}

Where $mytext is the buffer variable you mentioned. Note that I moved the namespace (the section no longer has a name, the surrounding let has), so the 'set' function works.
Hope this helps,

Vivienne

Matt Dorn

Monday 27 October 2003 9:38:05 am

Vivienne, you are a master! I guess my main problem was not knowing how to manipulate the namespace properly (I assumed you could nest them, and still be able to set the variables in the parent namespace).

Anyway, this works perfectly. Thanks so much for your help!

Matt

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu