Why doesn't this work?
Posted: Thu Oct 25, 2007 4:01 pm
I call a menu on the same page two ways:
{menu template="children" start_page="Design"}
{menu template="children" start_page="Build"}
The menu temlpate is like this:
{assign var="depth" value=$node->depth}
{foreach from=$nodelist item=node}
{if $node->depth == ($depth + 1)}
url}">{$node->menutext}
{/if}
{/foreach}
If I call it only once - it works perfectly - but when i display twice strange things happen and it shows the same children on both menu - and drops one of the last children off.
see: http://www.opeus.org/
it's called on the left and right
{menu template="children" start_page="Design"}
{menu template="children" start_page="Build"}
The menu temlpate is like this:
{assign var="depth" value=$node->depth}
{foreach from=$nodelist item=node}
{if $node->depth == ($depth + 1)}
url}">{$node->menutext}
{/if}
{/foreach}
If I call it only once - it works perfectly - but when i display twice strange things happen and it shows the same children on both menu - and drops one of the last children off.
see: http://www.opeus.org/
it's called on the left and right