views:

75

answers:

2

We have a custom master page that is deployed to My Site, as well as to the portal. The portal master page has an image, that the user clicks and directs them to the MySite application. On the My Site master page, we need to be able to facilitate the same functionality. When a user clicks on an image that is in the global navigation, they need to be directed back to the Portal. Since the portal will be deployed in different locations, I don't necessarily want to hard code the URL, nor do I want to leave it as an end user configuration (i.e. read the URL from a list). Is there anything in the SharePoint API that we can use that will provide us the URL for the main portal site collection?

A: 

You might be able to use $SPUrl:~SiteCollection/ See http://www.cleverworkarounds.com/2007/10/08/sharepoint-branding-how-css-works-with-master-pages-part-1/

strongopinions
A: 

The problem is that one MySite host is assigned to a Shared Service Provider and multiple web applications can be assigned to one Share Service Provider. So a MySite could be used for multiple web applications.

So without any meta infos or conventions it won't be possible to link back to the "right" site collection.

Flo