There's a bug in the MenuManager module.. I'm currently searching it, but perhaps someone else already knows where it is.
Structure of my test page:
2 root
2.1 child1
2.1.1 subchild1
2.2 child2
the markup:
{menu childrenof='root'}
the menu template:
<ul>
{foreach from=$nodelist item=node}
<li>{$node->depth} {$node->menutext}</li>
{/foreach}
</ul>
the result:
* 1 child1
* 2 subchild1
* 0 child2
MenuManager Bug
Re: MenuManager Bug
I use this as an ugly work-around:
{assign var="temp" value='.'|explode:$node->hierarchy}
{assign var="depth" value=$temp|@sizeof}
{assign var="depth" value=$depth-1}
{assign var="temp" value='.'|explode:$node->hierarchy}
{assign var="depth" value=$temp|@sizeof}
{assign var="depth" value=$depth-1}
Re: MenuManager Bug
Cant confirm this behavior used {menu childrenof='some page'} containg two sub pages each with children and my output is:
1.1
1.1.1
1.1.2
1.2
1.2.1
1.2.2
This looks correct to me. Used standard simple_navigation sample template.
1.1
1.1.1
1.1.2
1.2
1.2.1
1.2.2
This looks correct to me. Used standard simple_navigation sample template.
Re: MenuManager Bug
Okay, I've also tried it with simple_navigation now.
The instance var hierarchy works quite fine, so does not depth. Please replace hierarchy by depth and test again.
The instance var hierarchy works quite fine, so does not depth. Please replace hierarchy by depth and test again.
Re: MenuManager Bug
was already reported...
http://dev.cmsmadesimple.org/bug/view/6436
