Page 1 of 1

[SOLVED] Multiple Navigator Menus On The Same Page

Posted: Fri Mar 04, 2016 11:34 am
by govicinity
CMS Made Simpleā„¢ 2.1.2 Andros Town
CGExtensions 1.52.2
AceEditor2 1.05
CGSimpleSmarty 2.0.5
CGSmartImage 1.21
CMSContentManager 1.1
JQueryTools 1.3.8
Navigator 1.0.2
SiteMapMadeSimple 1.2.8

OK, it's Friday, and it's safe to say I must be having a "moment".

I am trying to import two menus onto one page, simple yes... not for me today.

I am using the code below to pull the two menus in with different css classes attributed to them:

Code: Select all

{Navigator loadprops='0' template="main_menu" start_level='1' number_of_levels='1'}
{Navigator loadprops='0' template="secondary_menu" start_level='2' number_of_levels='1'}
The thing is it only seems to want to pull in the "main_menu" template whatever I do, the only difference between the templates so far is:

main_menu

Code: Select all

{function name=Nav_menu depth=1}
<nav class="main-navigation">
<ul>
and

secondary_menu

Code: Select all

{function name=Nav_menu depth=1}
<nav class="secondary-navigation">
<ul>
Help greatly appreciated, as I just can't see what I'm doing wrong today, trying to get my head around the CMSMS 2 version and it's changes, this seems to be my last sticking point.

Re: Multiple Navigator Menus On The Same Page

Posted: Fri Mar 04, 2016 11:45 am
by govicinity
PS, just as a note, I have tried the template names as main_menu and mainmenu, secondary_menu and secondarymenu.

Re: Multiple Navigator Menus On The Same Page

Posted: Fri Mar 04, 2016 9:36 pm
by velden
Try to change the function name in ONE of the templates.

IIRC it's not possible to reuse/redeclare a function name.

Re: Multiple Navigator Menus On The Same Page

Posted: Mon Mar 07, 2016 9:59 am
by govicinity
Hi Velden, you're totally right, I actually did that, but the menu wasn't showing still, I have just realised I had display: none; on the secondary menu... as I said... I was having a bad Friday, couldn't see the wood for the trees. Thank goodness for the weekend and a small amount of sleep. Thanks again, hopefully this query post will help someone else out in the future anyway.