Multiple (top/left/etc) menus on the page

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
User avatar
Augustas
Forum Members
Forum Members
Posts: 241
Joined: Wed Oct 17, 2007 6:09 pm
Location: the world

Multiple (top/left/etc) menus on the page

Post by Augustas »

Hello,

I was wondering what is the best way to implement >2 different menus.
For example, one menu at the top of the page (horizontal) and another menu on the left side of the page (vertical).
Both contain different navigation options.

In CMSMS Admin: CONTENT -> PAGES I am able to organize only one menu.

What would be best solution for making the second menu?
- To create a User Defined Tag
- To create a new Module
- or something else?

Thanks,
Augustas
http://FollowTheRoad.com/ - living on the road...
http://www.kligys.com/ - asmeninis blog'as...
RonnyK
Support Guru
Support Guru
Posts: 4962
Joined: Wed Oct 25, 2006 8:29 pm
Location: Raalte, the Netherlands

Re: Multiple (top/left/etc) menus on the page

Post by RonnyK »

Augustas,

If you check "Top simple navigation + left subnavigation + 1 column" you'll see that that template calls menu twice, with different parameters.

I personally like to do all through the use of Content with different {menu}-callings, because that way I have all pages at the same place, in CONTENT, and am able to push pages where I want dynamically.

You can call menu, check the help of menumanager, with different parameters, f.e.:
(optional) includeprefix="" - Include only those items who's page alias matches one of the specified (comma separated) prefixes. This parameter cannot be combined with the excludeprefix parameter.
(optional) excludeprefix="" - Exclude all items (and their children) who's page alias matches one of the specified (comma separated) prefixes. This parameter must not be used in conjunction with the includeprefix parameter.
This will give you the option to show specific pages at specific placesm while excluding them at other positions. With the different calling of NEWS in a different position, inside a different container, you can also style them differently.

IF you check http://test.krijt.eu , I called {menu} 4 times there: hor, hor2, sidebar and footer.

Ronny
User avatar
Augustas
Forum Members
Forum Members
Posts: 241
Joined: Wed Oct 17, 2007 6:09 pm
Location: the world

Re: Multiple (top/left/etc) menus on the page

Post by Augustas »

Dear Ronny, thanks for the tip! That sounds very logical and comfortable.
Augustas
http://FollowTheRoad.com/ - living on the road...
http://www.kligys.com/ - asmeninis blog'as...
Post Reply

Return to “Developers Discussion”