|
Posted on
2009-11-17 11:25
懒人ABC
阅读( 696)
评论()
编辑
收藏
举报
Code <HTML> <HEAD> <SCRIPT LANGUAGE=javascript> <!-- function reSize() { try{ var oBody = ifrm.document.body; var oFrame = document.all("ifrm"); oFrame.style.height = oBody.scrollHeight + (oBody.offsetHeight - oBody.clientHeight); oFrame.style.width = oBody.scrollWidth + (oBody.offsetWidth - oBody.clientWidth); } //An error is raised if the IFrame domain != its container's domain catch(e) { window.status = 'Error: ' + e.number + '; ' + e.description; } } //--> </SCRIPT> </HEAD> <BODY onload=reSize()> <iframe onresize=reSize() id=ifrm src=YOUR_PAGE_HERE></iframe> </BODY> </HTML>
|