index.html的代码如下:
<iframe src="a.html"></iframe>a.html的代码如下:
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<frameset rows="30,*" cols="*" frameborder="NO" border="0" framespacing="0" id="frame1">
<frame name="top" scrolling="no" noresize src="top.html" frameborder="0">
<frame name="main" scrolling="auto" noresize src="main.html" frameborder="0">
</frameset><noframes></noframes>
</html>问题:
我如何让inde.html里的页面中的<iframe src="a.html"></iframe>中高度 自动适应main.html页面的高度呢?等到高人赐教~~谢谢
<iframe src="a.html"></iframe>a.html的代码如下:
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<frameset rows="30,*" cols="*" frameborder="NO" border="0" framespacing="0" id="frame1">
<frame name="top" scrolling="no" noresize src="top.html" frameborder="0">
<frame name="main" scrolling="auto" noresize src="main.html" frameborder="0">
</frameset><noframes></noframes>
</html>问题:
我如何让inde.html里的页面中的<iframe src="a.html"></iframe>中高度 自动适应main.html页面的高度呢?等到高人赐教~~谢谢
解决方案 »
- jquery的val()方法
- Extjs4.0 更新gird中一行样式的方法?
- 事件触发
- 有关parseFloat函数使用
- javascript在firefox下读取xml文件的问题,谢谢
- 一个通用的无限层次的、通用的联动列表类,请各位评评,并给予指点。
- 梅花雪大哥,您上次置顶的那篇关于树的帖子地址是什么,我找不到了~~~~
- 怎样将数字100,1不变,只是加后面的数,比如199,再加1就变成1100
- 求webvideoactivex.ocx控件的所有接口定义,只有登陆接口的定义也行
- highcharts X轴问题
- 页面刷新
- jquery中的setInterval后clearInterval,还能再重新setInterval吗?
<script type="text/javascript">
function reinitIframe(){
var iframe = document.getElementById("frame_content");
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);
</script>
框架页面 就不行了