Organization Chart Web part not working outside Mysite

mysiteorganizationchartSharePoint provides a great OOB web part to display the user hierarchy. This is called Organization Chart web part which when inserted inside a page of a MySite, displays hierarchical data.

Requirement:

Client wants the Org Chart inside a Portal’s page. Here Portal & MySite are two different web applications & upon using the Org Chart web part, it just shows blank area.

Note:

As per MS, the standard is to have MySite & Portal as 2 separate web applications.
This creates a problem as the Org Chart web part is somewhat coupled with MySite dependencies.
If MySite & Portal were inside same web application, then it will work without any tweaks.

Solution:

This is a case of cross domain issue since data is between 2 different domain.

In order for the web part to properly function on another web application, you have to add a clientaccesspolicy.xml file to the root of the IIS virtual directory for the Portal and MySite web applications.

For security reasons, you should limit this policy to only allow access to your Portal web application.

Creating the clientaccesspolicy.xml
[xml] <?xml version=”1.0″ encoding=”utf-8″?>
<access-policy>
<cross-domain-access>
<policy>
<allow-from http-request-headers=”*”>
<domain uri=”https://yourportal” />
</allow-from>
<grant-to>
<resource path=”/” include-subpaths=”true”/>
</grant-to>
</policy>
</cross-domain-access>
</access-policy>
[/xml]

Put the above file inside the root of both the Portal and MySite virtual directories.

 

Advertisements

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

Powered by WordPress.com.

Up ↑

%d bloggers like this: