Home » Documentation » Other WordPress plugins » Site Navigation

Site Navigation

IMPORTANT: The older CMS Navigation plugin has been deprecated in favor of the WPML plugin.

WPML CMS navigation includes:

  • Top navigation with top level pages and post categories including drop down items
  • Breadcrumb trail – showing where the current page is located in the website
  • Sidebar navigation – showing pages related to the one shown

Top Navigation

Drop down menu customization tool

The top navigation includes items for pages with no parent and post categories. No configuration is required.

You can style the top navigation bar using our drop down menu CSS generator. It allows styling the menu visually and creates the CSS code that needs to be added to your stylesheet file.

Breadcrumb Trail Navigation

This gives a trace going from the current page all the way up to the home page. For posts, it displays the post’s category. For pages, it goes up to the posts parents until the home page is reached.

This lets users see where they are in the website for every page they visit.

Sidebar Navigation

This creates local navigation for mini-sites inside the complete website. Let’s start with an example.

A few pages for a hotel will make up a mini-website. The structure will be:

  • Hotel Bella Vista
    • Rooms
    • Guest services
    • How to get there
    • Rates
    • Golf
    • Fishing
    • Ski classes

All the information pages are children of the hotel’s home – “Hotel Bella Vista”.

Grouping elements in sub-sections

We also want to make sub-sections, to make internal pages group easier. We want it to appear like this:

Hotel Bella Vista

Guest information (not a link!)

  • Rooms
  • Guest services
  • How to get there
  • Rates

Activities (not a link!)

  • Golf
  • Fishing
  • Ski classes

There will be no page such as ‘Guest information’ or ‘Activities’. These are just custom fields added to the child pages.

In order to build such a menu, we will need to know:

  1. Which is the home for the mini-site (in this case, ‘Hotel Bella Vista’).
  2. How the child elements are grouped
Mini home and sections

Mini home and sections

To tell the plugin that elements should be grouped together set the Section (in the CMS Navigation) for each child page. In this example above, Rooms, Guest services, How to get there and Rates all have the Section set to Guest information. The rest of the pages Golf, Fishing and Ski classes have Section set to Activities. This is optional. If not specified, the child page will not be grouped with others, but will still be listed.

WPML home page includes two section: Design Ideas and Get in touch.

Breaking large page hierarchies to smaller ones

By default, the left navigation tree will recursively scan all pages and include them. You can break it up into smaller trees. The advantages would be:

  • Less clutter and easier navigation
  • Only relevant pages can be displayed

To indicate that the plugin should not display the child elements of a page, select the ‘Mini home‘ checkbox in the CMS Navigation section.

The plugin will then include the page with this field, but not its child pages. Instead, when the page marked as Mini home is displayed, it’s child pages are included, but the parent pages are not. This enables you to include many mini sites in one large site.

For example, the getting started guide, in this website, is marked as a mini home. When you visit it, you don’t see the parent page in the sidebar navigation. Also, the child pages of that page don’t appear in the sidebar, when viewing the home page.

How to add the navigation elements to your WordPress theme

For information on how to add WPML navigation elements to your theme, go to the navigation section of the getting started guide.

Stuff we’re going to add

Here is a list of things we know this plugin needs to do, but haven’t yet implemented.

Feature Description Status
Management screen Provide AJAX interface that controls the way pages are organized.

  • Set the mini-home and sub-sections.
  • Control page order
  • Excluded pages
Done
Exclude pages Remove some pages from the tree navigation and drop-down menus. Done
Handle “page as homepage” and blog page. Handle this special case correctly in:

  • Breadcrumbs navigation
  • Sidebar navigation

There are some things that need to be done:

  • Make sure that the ‘news’ page goes to the static ‘blog’ page in case it’s assigned.
  • Make sure that the trail navigation doesn’t double list the static home page in case one is assigned.
  • When there is a ‘blog’, the trail navigation for the news page needs to point to it and not to the home page.
Done
Allow customizing home page and categories This would best be implemented simply in the function call (no admins screen).

  • Explicitly specify the ‘news’ page path.
Done
Fix drop down menus functionality for IE6 It works OK for Firefox, IE7 and other browsers but not IE6 Done
Auto adjust page order Automatically set the page order variables in all pages so that it will fit the current order of pages. This will work well with the AJAX page order control. Done

144 Responses to “Site Navigation”

  1. Sudoku says:

    “Next week we’re releasing a new version of CMS Navigation which will support IE6″

    Is this version 1.3 as released yesterday? If so, still doesn’t seem to be working with IE6. I get a huge top menu and overlapping text for parent/child items.

    Great with IE7, FF2, FF3, Op9, Saf3, even Netscape.

    Sorry if this is covered elsewhere but I can’t find a version history. Thanks.

  2. Pete Hawkins says:

    Unless I’ve got this wrong … when you upgrade to the latest version, you’ll have to redo your css if you’ve departed from that supplied. The classes and id’s have changed in 1.3.

    Hope I’m right and this helps!

    Pete

  3. jacobbrett says:

    Uh, 1.3 has completely broken my Nav’s CSS style… I hope this is an intentional change? Please get back on this as I don’t want to waste time updating it…

  4. Seth says:

    I really appreciate this plugin. Thank you! However, I have a major problem. I can’t get the name of the homepage to not show up in the navigation. I had it set so it wasn’t showing before, but now it is showing up on the website and making it look quite ridiculous. I have a navigation control plugin installed on my site, and it isn’t impacting the navigation at all like I want it to. Could you help me exclude the homepage from the navigation? I’m about to start ripping my hair out in frustration! lol

    Again, I appreciate your work, and any help you could give me would be greatly appreciated!
    Seth

  5. Maria says:

    Hi, Thanks for this great menu. I only have one problem. How do I change the colors and fonts to match my site theme? Right now it’s gray and I need it black. I also need to change the font type and color. I would be grateful for any assistance you could offer with this. Thank you.

    Maria

  6. Jillian says:

    AMAZING plugin! Perfect as a CMS plugin for my clients – however I just have one thing to ask, is there a way to display the Blog/News as Home, without the drop-down menu (this site does not use categories), and stick that link at the beginning of the list as opposed to the end?

  7. Seth says:

    Thank you! Thank you! Thank you!! My site looks much better with this new release!

  8. Franky says:

    have still problems with IE6. I run version 1.4 cms-navigate. (?)

  9. Pete Hawkins says:

    Hi, could any css ie guru help me please? mermanbarn.co.uk whilst not being perfect yet code yet is having issue with ie. The “a:hover” colour is showing in the top half of the menu bar whilst it should only appear on hover.

    I’ve tried little fixes for this but no-one have worked and fear that if I go deeper I’ll get myself totally stuck. Is this an ie box issue or have I done something fundamentally sily when changing the css to suit theme?

    Help appreciated, Pete

  10. Ben Paris says:

    sorry i’m a noob, how do i change the default “news” setting where my posts go?

  11. Rob Cubbon says:

    I found this plug in very helpful. Thank you!

  12. Nyree says:

    I installed the latest version of the plugin (1.4), but it still doesn’t work correctly in IE6. Will the new release fix the bug?

  13. Jake Goldman says:

    This is a great solution if you need a lot of different navigation features.

    We just released a plug-in designed to make one specific piece, side section navigation, very easy and customizable.

    Would love feedback:

    http://www.cmurrayconsulting.com/software/wordpress-simple-section-navigation/

  14. John says:

    When I attempt to activate plug-in I get message: “SitePress cannot be activated because your version of PHP is too old. To run correctly, you must have PHP5 installed.”
    But I have PHP5 installed for my site.
    Do I need to do something additional to get the plug-in to recognize PHP5?

    • admin says:

      The plugin asks PHP for its version and reports this error if it says PHP4. It’s possible that you have both PHP4 and PHP5 installed and PHP4 is actually running.

      Have a look here for instructions on how to test the PHP version of your website.

    • Peter says:

      I have found that if you do have both PHP4 and PHP5 you can create a “.htaccess” file in your plugin directory that contains the text “AddHandler x-mapp-php5 .php” to make Apache automaticaly interpret .php as .php5. Hope that helps. I am still sorting out a few issues that cropped up after I got past that hurdle. Namely “WPML cannot create the database tables! Make sure that your mysql user has the CREATE privilege”.

      • Pierre says:

        Hi, I have the same issue, namely “WPML cannot create the database tables! Make sure that your mysql user has the CREATE privilege” I am hosted with 1and1.com

        If you have any solutions, please let me know!

        Thanks

        Pierre

  15. Robert says:

    Hi

    When I use your menu system I do not get the blog page. The menu with Contender theme is pretty good but doesn’t work properly with IE – only Firefox.

    Any ideas?

    Thanks

    Robert.

    • Mihai says:

      Hi Robert,

      When you say you don’t get the blog page, you mean you don’t see a link similar to ‘Blog’ in the navigation menu of this site?

      In the WP admin under Settings » Reading what is you configuration for ‘Front page displays’ ?

      If ‘Your latest posts’ is selected, you blog is at your homepage. In the navigation menu you should see a list of categories if you enabled this from Sitepress » Navigation » Categories menu

      Let me know if this is not what you were looking for and I’ll assist you more. Would be great if you can include more details as well.

  16. NicoMollet says:

    Hey, the plugin is great. I am using it right now, but it lacks some feature I really need : mix pages and categories.

    For example, have a breadcrumb like this : Home > Page > Sub-Page1 > Category > Post
    And then the navigation sidebar would be :

    Page
    - Sub-page1
    — Category
    — SubSubpage
    - Sub-page2
    — SubSubpage
    — SubSubpage

    Do you think it is possible ?

    • Mihai says:

      Hi NicoMollet,
      I’m not really sure I understand your question correctly but for what I understand: WP doesn’t have a logic/support for nesting categories or posts under pages. I suppose you can still get what you want by using pages and ‘sections’ and the hierarchy you can set for these.

  17. denis says:

    Hi
    FYI, mailing list not working:

    “The feed does not have subscriptions by email enabled”

    regards.

  18. Robert Neuschul says:

    Site meta-management functions and navigation.

    Perhaps I’m being stupid, or misunderstanding the intentions and purposes of WPML, but I’m having difficulties working out how to control the overall framework of a site using WPML.

    For example, if I want to deploy a site in one language which will have no posts and no comments and no categories either – just a simple page based architecture, such that editors, authors and subscribers never ever see links to anything relating to Posts anywhere in their unique admin navigation console, then I can’t achieve this directly from anywhere within either the WP or WPML administration consoles. It seems I have to hack the theme templates to remove “posts” and “comments” or any references to them.

    Going in the opposite direction, if I want to leave posts in place and remove any reference to pages I have the same difficulty.

    Much the same seems to apply to the manner in which one can or cannot control and structure what particular classes of non-admin users will see in any particular sidebar – either on a per page or per sub-page basis in a context sensitive manner.

    Sure one can add sidebar widgets that give one such fine control, but isn’t the point of a CMS that one should be able to structure and manage the overall framework of a site without having to mess around with such extras?

    Am I being stupid? Or have I missed some obvious bits of instruction?

    • Mihai says:

      Hi Robert, I’m not sure I understand correctly your query. It seems to me something more generic than regarding WPML directly.
      The way most of the WP themes are built you don’t have to hack anything if you’re not going to use posts or pages. When content is missing nothing is sent to output. e.g. if you don’t have any posts a ‘recent posts’ widget will obviously not be displayed.

      You will, though, have to add the WPML hooks to the theme if you want to implement the site navigation this plugin is creating.

      The last part with the different user classes beign able to see certain sidebars I also don’t really understand… sorry.

      Please carry out this query on http://forum.wpml.org/ – it’s the place were you are more likely to get answers to any WPML related questions or just find the answers there.

  19. [...] CMS Navigation bietet Top Navi, Sidebar Menü und Breadcrumb – extrem gut und sehr einfach zu nutzen. [...]

  20. Jeff says:

    Any way you can add a span around the text to the main navigation so we can use the sliding doors technique?

    • Amir says:

      Hi Jeff,

      Actually, we’re planning to add something much more robust than just adding a SPAN around the menu items. What we’ll do is add a callback function, which you can add to functions.php. This function, if exists will be able to return custom HTML for menu items. It will receive the page ID and the menu level and will be able to cook its own HTML.

      This way you can add your SPAN, images and whatever else you like.

      Do you have any working sites with the effect you’re trying to achieve? I’d like to have a look and see that what we’re planning would be able to implement that.

      • Kit says:

        Amir, this sounds awesome and just what i need. Any idea when you will be releasing this?

        Thanks for a great plugin by the way.

        • amir says:

          We’ll include this in about two weeks (I hope that even before).

          The upcoming release (0.99) is still mostly about bug fixes and the next release will include significant feature additions, including this important feature.

          Are you subscribed to our email notifications? We announce all new features there in details.

  21. flavius says:

    hi,

    exclude pages doesn’t work for me, any idea why? thanks.

  22. mario says:

    Excluding Categories

    hi! I appreciate effort you put in this nice plugin. Though i have one question:

    is there a way to exclude some categories from Blog page (i.e. from Category menu)?

    for example when i want to show some of categoriy posts on some other pages and i dont want that category to be display on a Blog page.

    thx!

    • amir says:

      Hi Mario,

      It’s already on our todo list. We’ll be able to implement this in a couple of weeks, once we’re done working on the current issues.

  23. mario says:

    Hi Amir!
    nice to hear that! :-)

    cheers!

  24. kel says:

    Will this run under WP2.8? I only need the power/features of this but without the overhead of all that the new WPML plugin offers.

    Or… am I now obliged to use the WPML plugin?

    • amir says:

      WPML runs just fine under WP 2.8 (like this site is running at the moment). If you don’t need the multilingual features, just don’t enable them.

      • kel says:

        Thanks Amir – Just thought it might be making more DB queries than needed.

        • amir says:

          Actually, it isn’t. The plugin loads all the wp_options when it starts in one query (a very common practice for WP plugins). Then, it sees that the multilingual features are not used and it doesn’t load the database with them.

  25. is very simple to us and very nice.i like so much