用js
子窗口的参数传到父窗口中
window.opener.forms[0].txtA.value="return value";

解决方案 »

  1.   

    A 页面
    <% String tvalue = "";
    if(request.getParameter("tvalue")!=null){
        tvalue = request.getParameter("tvalue");
    }
    %>
    <form action="b.jsp" method="post">
      <input type="text" name="atext" value="<%=tvalue%>" />
      <input type="submit" value="提交" />
    </form>b 页面
    <% String tvalue = "";
    if(request.getParameter("atext")!=null){
        tvalue = request.getParameter("atext");
    }
    %>
    <a href = a.jsp?tvalue =<%=tvalue%>>返回A页面</a>手里没有现成的例子,大概给你写了这些,应该就是这样的。
      

  2.   

    request.setAttribute(String,Object)    request.getAttribute(String)
    或者session也可以,用完就remove。
      

  3.   

    同意 Ennis_wan(给上帝一双翅膀
      

  4.   

    这个我过去问过,已经解决了。
    这是源码。a.htm<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
    <title>无标题文档</title>
    <script language="JavaScript" type="text/JavaScript">
    <!--
    function MM_openBrWindow(theURL,winName,features) { //v2.0
      window.open(theURL,winName,features);
    }
    //-->
    </script>
    </head><body>
    <form name="form1" method="post" action="">
      <table width="400" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr> 
          <td width="94">&nbsp;</td>
          <td width="306">&nbsp;</td>
        </tr>
        <tr> 
          <td>&nbsp;</td>
          <td><input name="text" type="text" id="text"></td>
        </tr>
        <tr> 
          <td>&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
        <tr> 
          <td>&nbsp;</td>
          <td>&nbsp;</td>
        </tr>
        <tr> 
          <td>&nbsp;</td>
          <td><input name="Submit" type="button" onClick="MM_openBrWindow('/b.htm','','scrollbars=yes,width=300,height=400')" value="打开新窗口"></td>
        </tr>
      </table>
    </form>
    </body>
    </html>
    b.htm<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
    <title>无标题文档</title>
    </head>
    <script>
       function returnText() {
           window.opener.form1.text.value=form1.text.value;
       window.close();
       }
    </script><body>
    <table width="100%" height="300" border="0" cellpadding="0" cellspacing="0">
      <tr> 
        <td align="center"><form name="form1" method="post" action="">
            <input name="text" type="text" id="text" value="请输入你的内容">
            <br/>
            <input type="button" name="Submit" value="关 闭" onClick="returnText()">
          </form>
          
        </td>
      </tr>
    </table>
    </body>
    </html>
    这是网址http://community.csdn.net/Expert/topic/3170/3170466.xml?temp=.2616541
      

  5.   

    Ennis_wan(给上帝一双翅膀) 的可以最好用try,catch........
     A 页面<% String tvalue = "";
    try{
         tvalue=request.getParameter("tvalue");
       }
       catch(Exception e)
       {tvalue = "";}
    %>
    <form action="b.jsp" method="post">
      <input type="text" name="atext" value="<%=tvalue%>" />
      <input type="submit" value="提交" />
    </form>b 页面
    <% String tvalue = "";
    try{
       tvalue=request.getParameter("atext");
       }
       catch(Exception e1)
       {tvalue = "";}
    }
    %>
    <a href = A.jsp?tvalue =<%=tvalue%>>返回A页面</a>  
      

  6.   

    感觉用session是个不错的解决方案。有时我更喜欢用QueryString。
      

  7.   

    同意 Ennis_wan(给上帝一双翅膀) 给的方法