怎样固定iframe的高度阿?
下面是我的页面,当点击两个iframe中间的按钮时,下面的iframe向上移动了,总高度发身了变化;但是我要的效果是总高度不变的情况下,下面的iframe向上移动.
<%@ page contentType= "text/html; charset=GBK " %>
<html>
<head>
<title> </title>
<script type= "text/javascript "> // Example: obj = findObj( "image1 ");
function findObj(theObj, theDoc)
{
var p, i, foundObj;
if(!theDoc) theDoc = document;
if( (p = theObj.indexOf( "? ")) > 0 && parent.frames.length)
{
theDoc = parent.frames[theObj.substring(p+1)].document;
theObj = theObj.substring(0,p);
}
if(!(foundObj = theDoc[theObj]) && theDoc.all) foundObj = theDoc.all[theObj];
for (i=0; !foundObj && i < theDoc.forms.length; i++)
foundObj = theDoc.forms[i][theObj];
for(i=0; !foundObj && theDoc.layers && i < theDoc.layers.length; i++)
foundObj = findObj(theObj,theDoc.layers[i].document);
if(!foundObj && document.getElementById) foundObj = document.getElementById(theObj);
return foundObj;
}
</script>
<style type= "text/css ">
<!--
.ctrlbar {
background: #B2BFD2 url(images/bg_maincontent.gif) left repeat-y;
}
.explorer {
background: #B2BFD2;
border: 1px solid #B2BFD2;
}
.ctbutton {
font-family: Arial, Helvetica, sans-serif;
font-size: 8px;
background-color: #eeeeee;
border-width: 1px;
width: 100px;
height: 10px;
margin-bottom: 1px;
}
-->
</style>
</head>
<body>
<table width= "100% " border= "1 ">
<tr>
<td width= "100% " align= "center " valign= "top " class= "explorer " id= "menubar ">
<iframe name= "left " width= "100% " height= "100% " scrolling= "no " frameborder= "0 " >
<tr>
<td width= "800 " height= "60 "> <img src= "images/top.jpg " width= "800 " height= "60 "> </td>
<td width= "100% " background= "images/top_line.gif "> </td>
</tr>
</iframe>