Thursday, February 11, 2016

SharePoint 2013 Managed Navigation Lessons Learned

Posted in SharePoint, Technical By Kyle Wright @ 9/22/2013

This post is going to cover how to configure the global navigation bar in SharePoint 2013 using Managed Navigation, as well as provide some tips and lessons learned with rendering the global navigation using new Managed Navigation in a custom master page. If you want the full details of Managed Navigation, check
this article on Technet.

Setting up Managed Navigation

First, I’ll start with the Managed Navigation settings. I have found this extremely useful and I much prefer to manage the navigation use the term store than the traditional navigation tools. It is “possible“ to create a cross-site collection (or even web application) navigation using the Metadata Navigation tools, but you do have to do some additional work for that.

To get started, just head to the site settings page for your site collection and click Term Store Management under the Site Administration section. In the term store, click on the right edge of the Navigation group and select New Term Set:


Name your term set, then click the Intended Use tab, check the box for “Use this Term Set for Site Navigation” and press Save.


Click the right side of your term set and select Create Term.


Create all the terms for your navigation structure, then click the Navigation tab for a term. For this example, I am going to manually specify the destination URL, but you could easily use the Term-Driven navigation with friendly URLs if that meets your needs.


I have now built out my navigation structure:


Now that I have my navigation structure built, I can return to the site settings and set this as the navigation for my site. To do that, I’ll head to Site Settings, then click Navigation under the Look and Feel section. From the Global Navigation section, select Managed Navigation. A new section will appear on the page where I can select my term set that we created above. I’ll expand the Navigation group, then select my “Navigation Set 3” term set. Then, just head to the bottom and click OK.


So, now when we return to our site, we see all of our terms rendered as navigation items.


Using Managed Navigation in a Custom Master Page

Creating custom master pages is so much easier in SharePoint 2013 than it has been in previous versions, but it still isn’t quite perfect. For example, if you grab the Top Navigation snippet from the Design Manager for your master page, your Managed Navigation will not render correctly. This is an example master page with the Managed Navigation turned on, and the default top navigation snippet:


Pretty terrible right? It doesn’t render the drop down items at all. They are all rendered inline. You could obviously do your best to to apply JavaScript and/or CSS to get the drop-downs to function again, but why go through all that trouble when SharePoint should do that for you automatically. 

So, the easiest way around all this trouble is to grab the code that renders the top navigation from the HTML Seattle master page and paste that into your HTML master page. Here  is the code that is rendering the navigation in the Seattle master page for your copy/paste convenience.

   1:  <!--SPM:<SharePoint:AjaxDelta id="DeltaTopNavigation" BlockElement="true" CssClass="ms-displayInline" runat="server">-->
   2:      <!--SPM:<SharePoint:DelegateControl runat="server" ControlId="TopNavigationDataSource" Id="topNavigationDelegate">-->
   3:                       <!--SPM:<Template_Controls>-->
   4:                                       <!--SPM:<asp:SiteMapDataSource 
   5:                  ShowStartingNode="False"
   6:                  SiteMapProvider="SPNavigationProvider" 
   7:                  id="topSiteMap" 
   8:                  runat="server"
   9:                  StartingNodeUrl="sid:1002"/>-->
  10:          <!--SPM:</Template_Controls>-->
  11:      <!--SPM:</SharePoint:DelegateControl>-->
  12:      <a name="startNavigation"></a>
  13:      <!--SPM:<asp:ContentPlaceHolder id="PlaceHolderTopNavBar" runat="server">-->
  14:          <!--SPM:<SharePoint:AspMenu 
  15:              ID="TopNavigationMenu" 
  16:              Runat="server" 
  17:              EnableViewState="false"
  18:              DataSourceID="topSiteMap"
  19:              AccessKey="&#60;%$Resources:wss,navigation_accesskey%&#62;"
  20:              UseSimpleRendering="true"
  21:              UseSeparateCss="false"
  22:              Orientation="Horizontal"
  23:              StaticDisplayLevels="2"
  24:              AdjustForShowStartingNode="true"
  25:              MaximumDynamicDisplayLevels="2"
  26:              SkipLinkText=""/>-->
  27:                <!--PS: Start of READ-ONLY PREVIEW (do not modify)--><link rel="stylesheet" type="text/css" href="/_layouts/15/1033/styles/menu-21.css" /><div id="zz7_TopNavigationMenu" class=" noindex ms-core-listMenu-horizontalBox"><ul id="zz9_RootAspMenu" class="root ms-core-listMenu-root static"><li class="static"><a class="static menu-item ms-core-listMenu-item ms-displayInline ms-navedit-linkNode" tabindex="0" title="Default Publishing Site" href="#" accesskey="1"><span class="additional-background ms-navedit-flyoutArrow"><span class="menu-item-text">Default Publishing Site</span></span></a></li></ul></div><!--PE: End of READ-ONLY PREVIEW-->
  28:      <!--SPM:</asp:ContentPlaceHolder>-->
  29:  <!--SPM:</SharePoint:AjaxDelta>—>


Once we add that to our HTML master page, the navigation magically looks like this:


Just by grabbing a different snippet we saved ourselves all the trouble of building our own drop-down and fly-out navigation. If you need more fly-out levels, you can just update line 25 from the code above. 

Stay tuned for a future post to turn the navigation item above into this with some custom CSS branding:


If you have any questions regarding this post or C5 Insight's services and solutions, please contact us.

, , , ,


Got something to say? Join the discussion ┬╗
    Posted by LeonaL on 11/5/2015
    Hi Doug, thanks very much it worked and I have been struggling for ever. much appreciated
    Posted by Doug Allen on 11/5/2015
    LeonaL, if you set the MaximumDynamicDisplayLevels to 5, this will show 4 levels of dropdowns. I have verified this works.

    Posted by LeonaL on 11/5/2015
    Good day, I am using term store management on sharepoint server 2013 and it does not show my 4 level navigation. This worked fine on the foundation server. Any help will be appreciated
    Posted by Doug Allen on 2/2/2015

    You can see the CSS used with styling the top nav in Kyle's other blog post here:

    Posted by Ren Lyke on 2/2/2015

    Could you share the Custom CSS code that you used. I am unable to fine the next post regarding the same.

    Posted by Raghavendra on 2/7/2014
    I am also facing same issue, but above method not worked for me. Still Navigation is not loading in drop down. But it is working fine with Seattle master not with my custom master.
    Posted by C5 Insight Blogs - Microsoft SharePoint, Dynamics on 11/20/2013
    Trackback from C5 Insight Blogs - Microsoft SharePoint, Dynamics CRM and

    In a previous post I described how to use the Managed Navigation functionality that is new in SharePoint 2013 to create a global navigation based on a Managed Metadata term set. This post is going to provide you with all the CSS you need to fully brand... ...
    Posted by Kyle Wright on 9/24/2013
    Jeremy, thanks for your comments. No, you cannot use the same term set for more than one site collection. However, if you were just going to use a moderately sized term set and only use it on a few site collections, I don't think it would be too much work to use the "Reuse Term" function and copy your terms to another term set. This would at least allow you to update links once if they needed to change and have that flow across your site collections. Not sure if you mean 10,000 terms or site collections, but either way, this isn't for you. You would need a custom navigation at that point.
    Posted by Jeremy thake on 9/23/2013
    Nice post, does it work cross site collection? Say if I had ten thousand of them? Heard it couldn't and never had time to check.

leave a reply

 [Quick Submit with Ctrl+Enter]

Remember my details
Notify me of followup comments via e-mail


About C5 Insight

We are a Microsoft Gold Certified partner focusing on SharePoint, Microsoft Dynamics CRM and  Learn more about us by visiting our website.

We Wrote the Bible on Microsoft SharePoint and Dynamics CRMBook-Microsoft Dynamics CRM 2011 and SharePoint 2010 Bible

Upcoming Events

The Evolution of the Intranet: Creating a Culture of Collaboration

02/18/16 @ 3:00 PM ET This webcast will be broadcast LIVE from Transitioning Your Intranet to a Digital Workplace - See mo......

Deminar: Microsoft Social Engagement for Marketing, Sales, Service and Research

02/24/16 @ 2:00 PM ET In this deminar (that's demo + seminar) session, we will take a look at the Microsoft Social Engagem......

The 7 Deadly Sins of SharePoint: Planning Success and Avoiding Failure

03/10/16 @ 3:00 PM ET 60% of SharePoint projects are stalled, struggling, or failing, according to research conducted by t......

Top Downloads

SharePoint 2013 Feedback Solution - collect feedback from users into a custom feedback list that captures their feedback and exactly where they were in SharePoint when they provided it.

Why CRM Fails - research into CRM failure, best practices, and how to recover from a failing project.

The 60 Second Collaboration Readiness Self-Evaluation - is your team really ready to collaborate?  If they're not, software isn't going to help.  Take the quick self-evaluation in each department to understand how well your culture collaborates.

Identify Your Support Gaps - collaboration and CRM projects often fall short when it comes to supporting users, because support for these projects is different from other projects.  



The information herein may be used solely at your own risk.  No warranty is made by the author or by C5 Insight, Inc.

The opinions expressed herein are those of the individual authors and do not necessarily represent C5 Insight, Inc in any way.

Copyright 2011-2013 by C5 Insight