Cross domain restriction and limitations from an iframe

做~自己de王妃 提交于 2019-12-11 08:49:49

问题


Another site uses my iframe domain XYZ.COM. I want to get all html elements of that site (XYZ.COM) and work on it with javascript, just like I do with my own domain page, while using my iframe.

suppose wants to get images of XYZ.COM from iFrame

document.parent; // (its ask permission denied) 
document.referrer; // working for me but 
document.referrer.images; //Error: not an object

My debug tool is saying permission denied, because of cross domain restriction. Is there any solution for this, how can I do this?

来源:https://stackoverflow.com/questions/6732054/cross-domain-restriction-and-limitations-from-an-iframe

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!