可是当用户点击"刷新"键, there is no way to 不去刷新某些frame. Try to put the data in the cookies and load them in window.onload event

解决方案 »

  1.   

    如果你使用IE5+以上的浏览器,你可以把结果写到一个表单元素里,然后使用
    savsHistory Behavior来做:当然也可以用隐藏的表单元素啦<HTML>
    <HEAD>
    <META NAME="save" CONTENT="history">
    <STYLE>
       .saveHistory {behavior:url(#default#savehistory);}
    </STYLE>
    </HEAD>
    <BODY onbeforeunload="PersistInput.value='你数组的结果'">
    <INPUT class=saveHistory type=text id=oPersistInput>
    </BODY>
    </HTML>
      

  2.   

    如果你使用IE5+以上的浏览器,你可以把结果写到一个表单元素里,然后使用
    savsHistory Behavior来做:当然也可以用隐藏的表单元素啦<HTML>
    <HEAD>
    <META NAME="save" CONTENT="history">
    <STYLE>
       .saveHistory {behavior:url(#default#savehistory);}
    </STYLE>
    </HEAD>
    <BODY onbeforeunload="oPersistInput.value='你数组的结果'">
    <INPUT class=saveHistory type=text id=oPersistInput>
    </BODY>
    </HTML>
      

  3.   

    给你个使用ASP的例子(注:要将upper.html改为upper.asp):
    <%
    i=request.querystring("i")
    response.write i & "<br>"if i="" then
    dim testarr(10)
    attachstr=""
    for j=1 to 10
    testarr(j)=j
    attachstr=attachstr & "&" & "testarr" & j & "=" & testarr(j)
    next
    else
    for j=1 to 10
    response.write request.querystring("testarr" & j) & "<br>"
    next
    end if
    response.write attachstr & "<br>"
    %>
    <html><head>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312">
    <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <title>测试</title>
    </head><body <%if request.querystring("i")="" then%>onload="this.location='test.asp?i=10<%=attachstr%>'" <%end if%>></body></html>在这个例子中,页面刷新后,可以保存原来数组的值,你可以适当修改,以满足你的实际情况。