Question

Is there a way of making the links in the top navigation bar in SharePoint 2010 visible to only selected users/groups? I am running the Foundation version so I am limited with options. The SharePoint Server Publishing Infrastructure features are not available on this version.

Maybe the security trimming is an option?

Any help is appreciated.

Thanks in advance

Steve.C

Was it helpful?

Solution

As you said audiencing is not available with what you have. The only real option out of the box is the security trimming you mentioned. It is important to note that there are two kinds of links that will show up in the navigation. There are the objects that are shown, such as sub-sites or pages that are added (when it is configured to show those objects) and then there are the manual links that are added. Any manual link that is added is NOT security trimmed, and in fact SharePoint does not evaluate the url to validate if it is a SharePoint item or something in a non-SharePoint system.

The other alternative is to create your own navigation provider and data source. This would allow you to pull the data from anywhere including a SharePoint list or an XML file, and you then have the added benefit of controlling exactly how you want it to behave with relation to it being security trimmed, targeted to group membership, etc.

OTHER TIPS

Mike is absolutely right. One alternative the navigation could be to rely on your own navigation. Something i've used succesfully was this Mega-Menu driven by a List and a Web part. Find it here https://www.nothingbutsharepoint.com/sites/eusp/Pages/SharePoint-2010-and-Mega-Drop-Down-Menu-Navigation.aspx

What you need to do in addition it to add a People/Group column and put people in that column, while filtering the DataView already using [Me] via something like "Where Column X contains [ME]".

Stumbled across this old question, and I'd like to offer this tidbit of wisdom:

If you add the navigation nodes programmatically (like with PowerShell or C#), they will be security trimmed. Navigation added manually via the UI, however, is not.

Here's an article showing how to add nodes with PowerShell: SharePoint 2010: Security trimmed navigation

The basic code looks like:

using (SPSite site = new SPSite("http://theurl/tothesite"))
{
    SPNavigationNodeCollection nodes = site.RootWeb.Navigation.TopNavigationBar;
    nodes.AddAsLast(new SPNavigationNode("Title", "/siterelative/url"));
}

Or in PowerShell:

$web = Get-SPWeb "http://theurl/totheweb"
$nav = $web.Navigation.TopNavigationBar
$newLink = New-Object Microsoft.SharePoint.Navigation.SPNavigationNode -ArgumentList @("Title", "/siterelative/url")
$nav.AddAsLast($newLink)
$web.Dispose()

Hope this helps someone down the road.

Manually-added relative URLs are security trimmed.

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top