一:
function opennew(strValue)
{
    var new_window = window.open("new.jsp?strValue="+strValue);
}
然后在new.jsp中:
<input type=hidden value=<%request.getParameter("strValue")%>>
二:
利用showModalDialog[可以查阅MSDN的IEREF.chm和IEREF.chi看例子]
function AddNode()
{
var strPathName=window.location.pathname;
var inParameter="NULL"+","+"NULL"+","+GetSelectValue(document.forms[0].ModelID);
var outResult=showModalDialog(strPathName.substring(0,(strPathName.lastIndexOf('/')+1))+"Define_Node.jsp?Node=NULL&Action=NULL&ModelID="+GetSelectValue(document.forms[0].ModelID),inParameter,"dialogWidth:12;dialogHeight:6;dialogTop:400;dialogLeft:500;status:no;");
if(outResult=="False")
{
}
else
{
var outParameter=outResult.split(",");
var strOutNode=outParameter[0];
var strOutAction=outParameter[1];
var strOutNode_,strOutAction_;
strOutNode_=strOutNode.split("_");
strOutAction_=strOutAction.split("_");
document.forms[0].ListNode.length=document.forms[0].ListNode.length+1;
document.forms[0].ListAction.length=document.forms[0].ListAction.length+1;
var iLen=document.forms[0].ListNode.length;
document.forms[0].ListNode.options[iLen-1].value=strOutNode_[0];
document.forms[0].ListNode.options[iLen-1].text=strOutNode_[1];
document.forms[0].ListAction.options[iLen-1].value=strOutAction_[0];
document.forms[0].ListAction.options[iLen-1].text=strOutAction_[1];
}
}

解决方案 »

  1.   

    谢谢上面的哥们,不过第一种方法不能实现,因为我要获得的元素是放在table里面。其实我的问题是怎样在新开的new.jsp页面里面获得,原来的页面odd.jsp里面的table里面的单元格的值:)
      

  2.   

    兄弟该问题我已经解决了,解决的方法是:<BODY onLoad="star()">//打开页面的时候直接调用函数star()function star()
    {
    var location = "<%=request.getParameter("location")%>";//这里的location就是我选中的行标志
    var tab = window.opener.document.getElementById('tab');//这个就是我要的对象
    alert(tab.rows[location].cells[1].childNodes[0].value);//从table里面取出元素的值
    }马上结贴,虽然老兄的方法我用不上,不过表示感谢,送你50分,另外50分给我自己作为嘉奖啦:)
      

  3.   

    用下面的函数。
    form2是new.asp的form的name,form1是odd.asp的form的name
    <script language="javascript">
    <!--
    function check(){
    document.form2.bb.value=parent.document.form1.add.value;
    }
    -->