<script language=javascript>alert('您的信息反馈已成功提交,感谢您的参与!');history.go(-1);<script

宝宝妈妈2023-05-15  36

用到这句话<script language=javascript>alert('您的信息反馈已成功提交,感谢您的参与!')history.go(-1)</script>的页面是不是其它页面跳转过来的啊..如果不是的那当然没有反应了..

b.html

<html>

<head>

<title>

</title>

</head>

<body>

<A HREF="1.html">home.htm</A>

</body>

</html>

1.html

<html>

<head>

<title>

</title>

</head>

<body>

<script language=javascript>

alert('您的信息反馈已成功提交,感谢您的参与!')

history.go(-1)

</script>

</body>

</html>

这两个文件在同一文件夹中..你运行b.html在里面单机home.htm 这个连接看看效果

target不能这么写,然后直接写location.href的话针对的是当前页面,所以你要讲iframe里面的src改变成需要的jsp文件,我这里测试的是t.html,没有问题的。

<html>

<table>

<tr>

<td><a href="javascript:void(0)" onclick="javascript:document.getElementById('right').src='t.html'">test t</a></td><td><iframe name="right" id="right" width="300px" height="500px" src=""/></td>

</tr>

</table>

</html>


转载请注明原文地址:https://54852.com/read/666346.html