<IFRAME ID="IFrame1" name="IFrame1" marginwidth="0" marginheight="0" FRAMEBORDER="1" SCROLLING="yes" SRC="main.html" > </IFRAME>
<input type="button" value="获得" onclick="read()">
<script language="JavaScript">
<!--
function read(){
alert(IFrame1.frames['comright'].document.getElementById("otext").value)//document.getElementById("otext").value是右框架里的控件
}
//-->
</script>
objj=obj.document.getElementById("comright")
objj=obj.document.getElementById("comright")
objj.document.getElementById("otext").value
<IFRAME ID="IFrame1" name="IFrame1" marginwidth="0" marginheight="0" FRAMEBORDER="1" SCROLLING="yes" SRC="main1.asp" > </IFRAME>
<input type="button" value="获得" onclick="read()">
<script language="JavaScript">
<!--
function read(){
obj=document.getElementById("IFrame1")
objj=obj.document.getElementById("comright")
alert(objj.document.getElementById("otext").value)
}
//-->
</script>
<input type="button" value="获得" onclick="read()">
<script language="JavaScript">
<!--
function read(){
var objj=document.getElementById("IFrame1").contentWindow.frames['comright'];
alert(objj.document.getElementById("otext").value)
}
//-->
</script>
<input type="button" value="获得" onclick="read()">
<script language="JavaScript">
<!--
function read(){
var obj=document.getElementById("IFrame1").contentWindow
var objj=obj.document.getElementById("comright").contentWindow
alert(objj.document.getElementById("otext").value)
}
//-->
</script>