16/10/2010, 21:16:31
Code :
{strip}
{if $count > 0}
<ul class="topnav">
{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}
{repeat string="<!--Subnav Starts Here--><span>" times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}
{repeat string="<!--Subnav Ends Here--></span></li>" times=$node->prevdepth-$node->depth}
{elseif $node->index > 0 && $node->depth==1}</li>
{/if}
{if $node->depth == 1}
<li> <a href="{$node->url}" class="parent"{if $node->target ne ""} target="{$node->target}"{/if}> {$node->menutext} </a>
{else}
<a href="{$node->url}"{if $node->target ne ""} target="{$node->target}"{/if}> {$node->menutext} |</a>
{/if}
{/foreach}
{repeat string="</li></ul>" times=$node->depth-1}</li>
</ul>
{/if}
{/strip}