iframe ie下自动适应高度
2011-08-24 17:10
288 查看
function reinitIframe() {
var iframe = document.getElementById("frmContent");
try {
var bHeight = iframe.contentWindow.document.body.scrollHeight;
var dHeight = iframe.contentWindow.document.documentElement.scrollHeight;
var height = Math.max(bHeight, dHeight);
iframe.height = height;
} catch (ex) { }
}
window.setInterval("reinitIframe()", 200);
var iframe = document.getElementById("frmContent");
try {
var bHeight = iframe.contentWindow.document.body.scrollHeight;
var dHeight = iframe.contentWindow.document.documentElement.scrollHeight;
var height = Math.max(bHeight, dHeight);
iframe.height = height;
} catch (ex) { }
}
window.setInterval("reinitIframe()", 200);
相关文章推荐
- Iframe在火狐和IE自动适应高度
- Iframe自动适应宽度和高度(both IE and Firefox are ok)
- 兼容火狐和IE的javascript中iframe自动适应高度
- Iframe自动适应宽度和高度(both IE and Firefox )
- Iframe 自动适应屏幕高度
- 用iframe 自动适应高度
- css+div自动适应高度,在IE和firefox下都能适应 (左右DIV自适应高度)
- iframe自动适应高度及iframe中含有页签的高度动态适应方法
- 让iframe自动适应内容高度
- div 自动适应页面高度 IE vs Google浏览器
- iframe自动适应高度的多种方法方法小结
- iframe自动适应高度跨域
- Iframe 自动适应页面的高度示例代码
- iframe自动适应高度
- iframe页面高度自动适应
- 自动设置iframe的高度,谷歌,火狐, ie通用
- Iframe 自动适应页面的高度
- Iframe自动适应高度
- iframe高度自动调整(通过IE,firefox,opera测试)