Nested Repeat
Hi all
I have seen a couple of threads on this subject and I cannot quite make the connection to my own issues.
I am trying to create a dynamic menu where when you hover over one item (the parent group) then if there are any sub-items (child groups) then they are displayed. The data is pulled from a single table that has three fields:
pgegrp_id : (the unique numerical identifier 1, 2, 3, 4, etc.)
pgegrp_parent : (if this menu item is a parent then the field contains 0, if it contains a number then it is a child of the record whose pgegrp_id is the same as this record)
pgegrp_heading : (The text that appears as the menu item/sub item)
I can repeat the field okay using either Data Assist Repeat or DW's own Region Repeat.
My questions is how would I create the nested repeat so that the parent is displayed with child records immediately under their respective parent as follows:
<ul>
<li>Parent 1</li>
<li>Parent 2</li>
<ul>
<li>Parent 2/Child 1</li>
<li>Parent 2/Child 2</li>
<li>Parent 2/Child 3</li>
</ul>
<li>Parent 3</li>
<ul>
<li>Parent 3/Child 1</li>
<li>Parent 3/Child 2</li>
</ul>
Hope this makes sense and hope you can help.
Cheers
Gary