Export (0) Print
Expand All

SPSite.ValidateDomainCompatibility Method (String, String)

Verifies whether two URLs point to the same site collection, even if the domain portions of the URLs are different.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: Yes
Available in SharePoint Online

public static bool ValidateDomainCompatibility(
	string site1Url,
	string site2Url
)

Parameters

site1Url
Type: System.String
A string that specifies the absolute URL of the first site collection.
site2Url
Type: System.String
A string that specifies the absolute URL of the second site collection.

Return Value

Type: System.Boolean
true if the two URLs point to the same site collection; otherwise, false.

The domain portions of the URLs that are passed might be different, for example, because of alternate access mapping.

Community Additions

ADD
Show:
© 2014 Microsoft