Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have a (Publishing)Site Collection which have many sites and subsites. To meet a specific business requirement, I need the navigation settings of a site which is not in current context (It may be another subsite). We can use PortalSiteMapProvider to get the current navigation settings of a site as:

PortalSiteMapProvider provider=PortalSiteMapProvider.CurrentNavSiteMapProvider;

This gives reference to PortalSiteMapProvider of a site in current context. However, I need it for a site which is not in current context. Any ideas?

PortalSiteMapProvider has a property named CurrentWeb which can be set to a SPWeb object. I am not sure if we can use this property.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

What i read from your question, correct me if im wrong, is you want the navigation to span across site collections.

The OOB hierarcical navigarion providers cannot so this.

There is an MSDN article that can work as a primer to get started here. You can also find several examples on codeplex and by googling Cross Site Collection Navigation.

The way i solve this, is with a custom hierarcical navigation that we populate with search, combined by adding html meta tags and managed properties that contain order and match pattern for selecting parent sites. It is implemented with minimal footprint by using delegate controls.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.