首页  >  文章  >  web前端  >  iframe高度从内向外撑起_html/css_WEB-ITnose

iframe高度从内向外撑起_html/css_WEB-ITnose

WBOY
WBOY原创
2016-06-24 11:48:31983浏览

index.html:

<div style="height: 200px;"></div><iframe id="gys" src="con.html" width="100%"></iframe>

 

con.html

<body onload="parent.window.document.all.gys.height=document.body.scrollHeight">        <div style="height: 1800px; width: 500px; margin: 0 auto; "></div>    </body>

 

ok了.

声明:
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn