Navigation : Pages


When dealing mainly with pages, sometimes we fall on concern caused by a limitation of SharePoint , ie the number of pages displayed in navigation natively.

Indeed, SharePoint limits the number of pages displayed at 50 (here the example in the current browser).

While we have, for example, 51 pages:

To overcome this limitation, we must add a parameter in the configuration file of the web application: the web.config

Start by identifying the part sitemap and especially the 4 nodes “CMS”

 
<siteMap ... >       
<providers> 
..         
<add name="GlobalNavSiteMapProvider" description="CMS provider for Global navigation" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Global" EncodeOutput="true" />         
<add name="CombinedNavSiteMapProvider" description="CMS provider for Combined navigation" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Combined" EncodeOutput="true"/>         
<add name="CurrentNavSiteMapProvider" description="CMS provider for Current navigation" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Current" EncodeOutput="true"/>         
<add name="CurrentNavSiteMapProviderNoEncode" description="CMS provider for Current navigation, no encoding of output" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Current" EncodeOutput="false" /> 
...       
</providers>     
</siteMap> 

At these nodes we will add a new parameter: DynamicChildLimit

This parameter takes an integer that determines the number of items to display. The default is 50. Set this to 0 removes the limit.

Example:

DynamicChildLimit = “10” to display 10 items
DynamicChildLimit = “60” to display 60 items
DynamicChildLimit = “0” to display all items as we wish now

So we have in our web.config file

 
<add name="GlobalNavSiteMapProvider" description="CMS provider for Global navigation" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Global" EncodeOutput="true" DynamicChildLimit="0" /> 
<add name="CombinedNavSiteMapProvider" description="CMS provider for Combined navigation" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Combined" EncodeOutput="true" DynamicChildLimit="0" /> 
<add name="CurrentNavSiteMapProvider" description="CMS provider for Current navigation" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Current" EncodeOutput="true" DynamicChildLimit="0" /> 
<add name="CurrentNavSiteMapProviderNoEncode" description="CMS provider for Current navigation, no encoding of output" type="Microsoft.SharePoint.Publishing.Navigation.PortalSiteMapProvider, Microsoft.SharePoint.Publishing, Version=12.0.0.0, Culture=neutral,PublicKeyToken=71e9bce111e9429c" NavigationType="Current" EncodeOutput="false" DynamicChildLimit="0" /> 

We save this file (the backup triggers a iisreset automatically) and return to our site

We can see that our 51st page appeared in the navigation.

In the Quick Launch

In the navigation menu at the global navigation

And in the navigation menu at the current browser

Christopher.

Article originally posted on 03/05/2010 on Areaprog

Advertisements
This entry was posted in SharePoint 2007 and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s