注册 登录
编程论坛 ASP技术论坛

打开页面后不能后退?

fsx 发布于 2007-09-06 10:33, 1293 次点击
请问在aa.asp中我用Response.Write "<script language=JavaScript>{parent.location='xx.aspx';}</script>"跳转到xx.asp页面后,按“后退”按钮后不能后退到aa.aspx页面。请问如何才能实现?谢谢了!
6 回复
#2
月夜2007-09-06 10:52
嘿嘿 很简单啊 在xx.asp做个<a href=aa.asp>返回</a>
#3
fsx2007-09-06 11:36
不是啊,我规定要用response.write来实现的。你说的那个想并谁都懂。还是要谢谢你!有谁懂吗?
#4
hmhz2007-09-06 11:40
Response.Write "<script language=JavaScript>{alert("确定要返回吗?"); parent.location='xx.aspx';}</script>"

[此贴子已经被作者于2007-9-6 11:40:32编辑过]

#5
fsx2007-09-06 12:29

能跳转的,而是不能后退啊!

#6
ayue2222007-09-06 12:31
使用location.href或window.open方式的页面是不能后退到上一页的..
#7
fsx2007-09-06 14:17
那怎么办?
我是这样的做的。
首先在aa.asp页面的dropdownlist读取绑定数据表中一字段,该字存储网址,设置dropdownlist事件处发
Response.Write "<script language=JavaScript>parent.location='等于dropdownlist选择项的值';}</script>"。
然后在xx.aspx页面中用<iframe src="aa.aspx"></iframe>,要求导航时内容在父窗口(xx.aspx)显示。
导航后按“后退”按钮不会回到xx.aspx页面。
1