父页 1.asp ,用showModalDialog()弹出网页对话框 2.htm ,请问 2.htm中的<input name="01" type="text" id="01">怎样向 1.asp 的 <input name="02" type="text" id="02">传递参数?

解决方案 »

  1.   

    2.html往回传??那只好用提交表单了
      

  2.   

    弹出页面中两个值sDate,sTime赋给它父页面相对应元素,并关闭弹出页面
    window.opener.document.all.bookingDate.value = sDate;
    window.opener.document.all.bookingtime.value = sTime;
    window.close();
      

  3.   

    2.htm上加个按钮
    <input type="button" onclick="returnValue();"><script>
    function returnValue(){
    window.opener.document.getElementById("02").value = document.getElementById("01").value;
    }
    </script>点击按钮后2.htm中<input name="01" type="text" id="01">的值就传回1.asp 的 <input name="02" type="text" id="02">中