假设该页面为test.jspleft帧不设置src属性,这样打开test.jsp页面时,left页面就不会被读取了。然后在test.jsp中增加一个window.onload方法,设置left的链接
例子如下:
<script>
function window.onload(){
this.left.location="http://www.csdn.net";
alert(this.main.document.all("show").value);
}
</script>
<iframe name="left" src="about:OK"></iframe>
<iframe name=main src="about:<input name=show value=100>" ></iframe>