Welcome to Support!

Search for an answer or ask a question of the zone or Customer Support.

Need help? Dismiss Show All Questions sorted by Date Posted

Show

sorted by

Nishant Khandelwal Nishant Khandelwal

Unable to Access other home page from the custom home page components..getting -: Uncaught DOMException: Blocked a frame with origin "https://c.ap2.visual.force.com" error

Hi All,
I am trying to access home page from an custom home page component ie of type VF area, through JS but getting "Uncaught DOMException: Blocked a frame with origin "https://c.ap2.visual.force.com" from accessing a cross-origin frame.(…)". Tried setting the document.domain= 'ap2.salesforce.com' for the home page component but unsuccessful. Also routing the vf page to the home page is not helping.
Please any one suggest me how to resolve this.

Thanks
Nishant
Best Answer chosen by Nishant Khandelwal
pcon pcon
This is a limitation of how Salesforce handles this type of Visualforce page.  By putting them in an iframe you will not be able to access anything outside of that iframe [1].

[1] http://stackoverflow.com/questions/25098021/securityerror-blocked-a-frame-with-origin-from-accessing-a-cross-origin-frame