Jump to content

Menus: How to Remove Page from NavBar?


wiredny
 Share

Recommended Posts

Yes, I am using the default profile. The navbar appears on the homepage.  I fixed the problem by going into site/templates/header.inc and commenting out the line"$children->prepend($homepage);" within the following code snippet:


            
                // Create the top navigation list by listing the children of the homepage. 
                // If the section we are in is the current (identified by $page->rootParent)
                // then note it with <a class='on'> so we can style it differently in our CSS
                // and add a text that is visually hidden, but available for screen readers.
                // In this case we also want the homepage to be part of our top navigation, 
                // so we prepend it to the pages we cycle through:
                
                $homepage = $pages->get("/"); 
                $children = $homepage->children;
                // $children->prepend($homepage); 
        

 

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...