呵呵, 一样的代码, 我这里就从没有出现过类似的问题function changeIframeHeight() //自动改变 Iframe 的高度
{
if(top != self)
{
window.parent.document.getElementById(self.name).height = document.body.scrollHeight;
}
}
function window.onload()
{
changeIframeHeight(); //改变 Iframe 高
}
{
if(top != self)
{
window.parent.document.getElementById(self.name).height = document.body.scrollHeight;
}
}
function window.onload()
{
changeIframeHeight(); //改变 Iframe 高
}
if(self.name!="yunshui")
{self.location.reload()
self.name="yunshui"
}
<script>
if (self.location!=top.location)
{
parent.window.document.all.iframe1.height=document.body.scrollHeight +20;
}
</script>
</body>这样试试
就是从servlet返回的xml用xsl(jsp扩展名)处理之后有这个问题。