简体   繁体   English

从 Iframe js 内部获取容器域

[英]Get container domain from inside the Iframe js

I'm trying to get the domain name of the host website of my Iframe is there a way to do that?我正在尝试获取我的 Iframe 的主机网站的域名有没有办法做到这一点? I would really appreciate any help regarding this issue.我非常感谢有关此问题的任何帮助。 Thanks in advance.提前致谢。

so I got the answer after working on it for a while we can get the url from the host website by using this method or by adding the an event to the iframe like this but yeah its working now 所以我在研究了一段时间后得到了答案,我们可以通过使用这种方法或通过将事件添加到 iframe 像这样从主机网站获取 url,但它现在可以工作了

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM