MenuManager/Navigator differences with CMS upgrade to v2
Posted: Sat Jun 30, 2018 8:44 pm
So, I’m upgrading a site from CMS 1.12.2 to version 2 and am experiencing differences in the way the Navigator module displays my menu structure compared to how MenuManager did it.
My default menu template in MenuManager looked like this:
which is pretty similar in logic/structure to the minimal_menu.tpl template that came with the CMS (verson 1), except a few different class names.
I was calling the menu on my pages with this tag:
This showed the two page items and their direct children as sub lists. However, this doesn’t seem to work anymore with the Navigator; in the new version it just shows the two page items and no children. Has this been a bug in MenuManager that has been “fixed” now, where I have to find a different implementation in order to get the same functionality or is there anything else I’m missing?
My default menu template in MenuManager looked like this:
Code: Select all
{if $count > 0}
<ul class="nav">
{foreach from=$nodelist item=node}
{if $node->depth > $node->prevdepth}
{repeat string="<ul>" times=$node->depth-$node->prevdepth}
{elseif $node->depth < $node->prevdepth}
{repeat string="</li></ul>" times=$node->prevdepth-$node->depth}
</li>
{elseif $node->index > 0}</li>
{/if}
{if $node->current == true}
<li class="current"><a href="{$node->url}"{if $node->target ne ""} target="{$node->target}"{/if}>{$node->menutext}</a>
{elseif $node->parent == true and $node->type != 'sectionheader' and $node->type != 'separator'}
<li class="current parent"><a href="{$node->url}"{if $node->target ne ""} target="{$node->target}"{/if}>{$node->menutext}</a>
{elseif $node->type == 'sectionheader'}
<li class="section">{$node->menutext}
{elseif $node->type == 'separator'}
<li class="separator"><hr/>
{else}
<li><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}
I was calling the menu on my pages with this tag:
Code: Select all
{menu loadprops=0 number_of_levels='2' items='verein, projekte'}