Multiple menu's / navigation structures?

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Locked
djprozac

Multiple menu's / navigation structures?

Post by djprozac »

Hello all!

A site I am currently developing is made up of two parts which deal with totally seperate subjects.
When the user comes to the front page he can choose which part of the site he wants to visit.

Now here's the problem: when adding pages to the site they show up in the menu's of both parts. Since both parts should be totally seperate, this is not good.
Is it possible to have a seperate menu for each part of the site? So menu links for one part dont show up in the other and vice versa? Maybe some specific tweaking of the menu template?

Any help would be greatly appreciated!
User avatar
Nullig
Power Poster
Power Poster
Posts: 2380
Joined: Fri Feb 02, 2007 4:31 pm

Re: Multiple menu's / navigation structures?

Post by Nullig »

Well, you could arrange your pages into 2 sections:

1.0 Section 1
  1.1 Subsection 1.1
  1.2 Subsection 1.2
  1.3 Subsection 1.3
2.0 Section 2
  2.1 Subsection 2.1
  2.2 Subsection 2.2

and so on.

You would have a main page that has a template that shows only the 1st level menu (Section 1 and Section 2) which are links to new pages with different templates that show one or the other group of subsections.

Nullig
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: Multiple menu's / navigation structures?

Post by calguy1000 »

To continue on the above thead, you would just need to change your {menu } call a bit depending upon which section you're in.

something like {menu start_page=$page_alias show_root_siblings='1'}

This would only show anything that is at the same level, or deeper than the current page.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
djprozac

Re: Multiple menu's / navigation structures?

Post by djprozac »

Fantastic, thanks for the help guys!
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Multiple menu's / navigation structures?

Post by Dr.CSS »

You will need to make "1.0 Section 1" and "2.0 Section 2"  section headers that are not shown in the menu then your menu calls will start with the "1.1 Subsection 1.1" and "2.1 Subsection 2.1" I use  start_element="8.1"  as in this which has four menus that can be taken out individually from diff. templates for subpages...

               
                {menu template="menu2" start_element="8.1" show_root_siblings="1"}
               
                {menu template="menu2" start_element="8.2.1" show_root_siblings="1"}
                {menu template="menu2" start_element="8.3.1" show_root_siblings="1"}
               
                {menu template="menu2" start_element="8.4.1" show_root_siblings="1"}
               

this is the template... http://multiintech.com/kidney/
this is a subpage template... http://multiintech.com/kidney/index.php ... plush  you will notice the menu2 section is missing...

1>7 are shown in the menu, Left Menu, menu2, menu3, menu4, and testimonials are not shown in the menu and 8.1.5, 8.2.1.14, 8.3.1.3 are the separators between the menus which here are images...

link to image of menu structure... http://multiintech.com/webshots/mascot.png
original image i worked from... http://multiintech.com/webshots/newmascot.png
Locked

Return to “CMSMS Core”