Jump to:

17452 Posts in 4473 Topics by 1971 members


SilverStripe Forums » Archive » Generate 2 different Navigations

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Page: 1
Go to End
Author Topic: 1856 Views
  • Synaps1s
    8 Posts

    Generate 2 different Navigations Link to this post

    Hi Everyone, im totally new to SilverStripe but already impressed about it. I really starting to loving this CMS, still im a totally newbie to this platform, i read the first 2 Tutorials, and made some custom Templates, but i have an simple problem, i want to have to different Navigations on one Page, NOT A 2ND Level Navigation but let say to Groups of Navigation, on for the Header, and another one for Footer.

    The Problem is i don't know how to Group the Pages in CMS or how to make two different Navigataion Groups..
    What i mean, when i generalte an list navigation based on the tutorial, this is fine, but let's say i want the last 3 links appear in an plaece in footer.. i could make this static, but i want to learn the possibilities of silverstripe.

    Can anybody help out?

  • Willr
    Forum Moderator
    5511 Posts

    Re: Generate 2 different Navigations Link to this post

    its messy but for a couple of sites I have done we needed a seperate footer menu (check out http://graphics.onslownet.school.nz for my example) so what I did in the cms is create a page called FooterMenu (might want to unselect 'ShowInMenus' and ShowInSearch as you dont want too many people actually going to this page ) then adding children to that page of the Page Type 'Redirector'.

    Then in the template you can control the children of that FooterMenu (I have cut out the extra HTML)

    <% control ChildrenOf(FooterMenu) %>
    <a href="$Link">$MenuTitle</a>
    <% end_control %>

    Its not pretty but it works

  • Synaps1s
    8 Posts

    Re: Generate 2 different Navigations Link to this post

    That's exectly what i thought in the first place, but was thinking there is some other nice way to do it, like setting a flag or id on the pages ;]

    Thanks for help! Gotta do it the same way!

  • newjamie
    Community Member
    7 Posts

    Re: Generate 2 different Navigations Link to this post

    I need to do this in a way that is hierarchically correct in my site tree.

    Is there not a better way to do this in SilverStripe now?

    I could really use a solution!

    Basically, My main nav appears in 6 places on my templates and need to split it up 6 ways to show it.


Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.