A页面test3.asp代码:
<form action="do3.asp" method="post" name="form1" target="_blank">
<input type="radio" name="id" id="radio<%=(subcate.Fields.Item("id").Value)%>" value="<%=(subcate.Fields.Item("id").Value)%>" onclick="document.form1.submit();javascript:location='do3.asp'">
B页面do3.asp代码:
..... '处理过程
<% response.redirect "test3.asp" %>
把你的代码加进来成:
..... '处理过程
<% response.redirect "test3.asp" %>
<script>window.close()</script>
不管用,是我写得不对吧?

解决方案 »

  1.   

    response.redirect "test3.asp"  ASP的代码先执行于JS代码你的do3.asp永远也执行不到<script>window.close()</script>
    这一行就跳转了可以把 response.redirect "test3.asp"改成  response.write "<script>location.href='test3.asp'</script>"
    给分吧.....
      

  2.   

    你可以在窗口的onunload事件里做文章.
      

  3.   

    <body onload="func()">function func(){
      //你的处理
      window.close();
    }
      

  4.   

    我的处理过程是把上一页传递过来的数据插入到新表中以及对另一个表的记录进行修改,那用"铭轩"的方法的话,我如何把我的处理过程加到
    function func(){  window.close();
    }
    中去啊?
    我的过程是这样的:
    <%if(request.form("id") <> "") then xg__varid = request.form("id")%>
    <%set xg = Server.CreateObject("ADODB.Command")
    xg.ActiveConnection = MM_kaoshi_STRING
    xg.CommandText = "UPDATE answer SET selected=1 WHERE id=" + Replace(xg__varid, "'", "''") + ""
    xg.CommandType = 1
    xg.CommandTimeout = 0
    xg.Prepared = true
    xg.Execute()%>
      

  5.   

    我来告诉你。先有一个form,就是所谓的a页面。<input name="categoryId" type="hidden" value="">
              <input name="categorytext" type="text" size="40">
              <input type=button style='width:60' value="Choose..." onClick="javascript:window.showModalDialog('b页面', window, 'dialogHeight: 400px; dialogWidth: 350px; dialogTop: 200px; dialogLeft: 300px; edge: Raised; center: yes; help: no; resizable: no; scroll: yes; status: no;')">
    在这里把window作为参数传进showModalDialog中去,即第二个参数。
    然后再第二个页面b页面中,触发某个时间后执行javascriptfunction selectedNode(ob, id, name) {
        //对a页面中的进行赋值
    window.dialogArguments.document.getElementById('categoryId').value = id;
    window.dialogArguments.document.getElementById('categorytext').value = name;
    window.close();//关闭b页面
    }
      

  6.   

    <SCRIPT LANGUAGE="javascript">
    {
    window.setTimeout("aa()",3000,"javascript");
    function aa()
    {
    link.click();
    }

    </SCRIPT>
    <a href="javascript:history.back(-1);" id="link">Back</a>
    3秒钟之后自动返回,或者按下back返回