Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Template Questions

Second individual menu/navigation


Reply

2 Posts   763 Views

Avatar
langhauserit

21 January 2012 at 5:06am Community Member, 1 Post

Hey Guys,

i do the first migration from a website to SilverStripe CMS and i need your help for a individual menu/navigation.

My normal navigation in the header and the submenu navigations works fine, but i need a third navigation in the footer. The heaviness is that i need to select which menu item will be shown in the footer navigation. So maybe there will be different selections for the main and the footer navigation. The menu item "Home" is shown in the main navigation but we won't show it in the footer navigation. In the other way i can use the selectbox "don't show in menu" so that a menu item will be shown in the footer navigation but not in the main navigation. I already tried the special menu (http://bit.ly/zuDW8F), but i can't use children in there.

I hope you can help me.

Thanks and Greetings from Munich.
Oliver

Attached Files
Avatar
martimiz

23 January 2012 at 6:18am (Last edited: 23 January 2012 6:19am), Forum Moderator, 1091 Posts

What I usually do is create a boolean AddToFooterMenu to the Page class, and create a checkbox field for it in the CMS.

IF the only thing needed is a single layer footermenu, I just create a getFooterMenu() function in the Page_Controller that returns a DatObject::get of all pages where AddToFooterMenu = false... In a multlayers itemap kind of menu you could also do a <% if AddToFooterMenu %> in your templates menu control loops...