Jump to:

17452 Posts in 4473 Topics by 1971 members

Archive

SilverStripe Forums » Archive » Navigation Variables - is this is all there is?

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: 1380 Views
  • sarahk
    Avatar
    Community Member
    46 Posts

    Navigation Variables - is this is all there is? Link to this post

    According to Tutorial: Making a Navigation System when I'm in the navigation loop I have the following variables to work with

    * $Link
    * $Title
    * $MenuTitle
    * $LinkingMode

    Are there any other variables?

    I'd really like to know the type of page and be able to use the CSS to format the link accordingly.

    thanks

  • Willr
    Avatar
    Forum Moderator
    5462 Posts

    Re: Navigation Variables - is this is all there is? Link to this post

    you have access to every field on that pages object. See the lists at the right down the bottom of the page - http://doc.silverstripe.com/doku.php?id=built-in-page-controls for a complete list

  • sarahk
    Avatar
    Community Member
    46 Posts

    Re: Navigation Variables - is this is all there is? Link to this post

    Thanks Will

    $ClassName is what I was looking for.

    Seems I'll need to create an extension of the contact page as I have 2 on the nav and only one needs to be highlighted. In the CMS you have userdefinedform in a pagetypes folder. If I'm going to "extend" that type does it go in my code folder or do I need to copy the folder structure from cms?

  • Sean
    Avatar
    Forum Moderator
    921 Posts

    Re: Navigation Variables - is this is all there is? Link to this post

    Seems I'll need to create an extension of the contact page as I have 2 on the nav and only one needs to be highlighted. In the CMS you have userdefinedform in a pagetypes folder. If I'm going to "extend" that type does it go in my code folder or do I need to copy the folder structure from cms?

    You should be able to do the former - put it into your code folder.

    1380 Views
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.