如何根据跨域内容设置iframe的高度,我无法访问? [英] How do I set the height of an iframe based on content which is cross domain and I have no access?

查看:71
本文介绍了如何根据跨域内容设置iframe的高度,我无法访问?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,我在我的页面中使用iframe来调用第三方网站。现在,我们的网站是一个响应式网站,我们确实希望跨域网站能够做出响应。基本上,iframe不应该随时显示任何垂直滚动条。其高度应根据其含量增加/减少。既然,这是跨域第三方,我真的没有权限在那里更改任何脚本。我注意到的是我的页面首先加载然后加载iframe。如果我没有给iframe提供任何高度,它会以最小高度加载。



我已经通过多个解决方案来讨论我不能做的跨域脚本。有人可以指导我正确的方向吗?



谢谢。

Hello, I am using an iframe inside my page which calls a 3rd party website. Now, ours is a responsive website and we do want the cross-domain website to be responsive as well. Basically, the iframe should not show any vertical scroll bar at any time. Its height should increase/decrease based on its content. Since, this is cross domain 3rd party, I really dont have access to change any script there. What I noticed is my page loads first and then the iframe. If I dont give any height to iframe, it loads with a minimum height.

I have been through multiple solutions which talk about cross-domain scripting which I cannot do. Can someone guide me in right direction?

Thanks.

推荐答案

你所做的很明显不道德,谢天谢地也不可能。
What you're doing is obviously unethical, and thankfully not possible either.


这篇关于如何根据跨域内容设置iframe的高度,我无法访问?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆