I'm trying print HTML required for tabbed content, but am struggling to get this to work. (5.1.9)
I'm trying to do this via a parent/child nested asset listing setup and using list_current_asset_id to access a parent's variable.
I've successfully used list_current_asset_id in the past when nesting within a parent'sType Formats Bodycopy, but in this instance I need to nest within the parent's Page Contents Bodycopy.
My end result is to print the following HTML:
<div class="tabs"> <ul class="nav"> <!-- asset listing one --> <li><a href="#tab1">Tab one link (from asset name)</a></li> <li><a href="#tab2">Tab two link</a></li> ... </ul> </div> <div class="tab-content"> <!-- asset listing two --> <div id="tab1">Tab one contents (from asset contents)</div> <div id="tab2">Tab two contents</div> ... </div> </div>
I hope that translates, let me know if I need to make anything clearer.
Cheers in advance for any advice.