<iframe id="iFrame1" name="iFrame1" width="100%" onload="this.height=iFrame1.document.body.scrollHeight" frameborder="0" src="index.htm"></iframe>看到了吧,关键就在于onload="this.height=iFrame1.document.body.scrollHeight"!
实现iFrame自适应高度,原来很简单!
转载本文章为转载内容,我们尊重原作者对文章享有的著作权。如有内容错误或侵权问题,欢迎原作者联系我们进行内容更正或删除文章。
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
实现iFrame自适应高度,原来很简单!(绝对能用)javascript hive html