IE7、8关闭窗口时总是提示的解决办法
代码 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html xmlns="http://www.w3.org/1999/xhtml">
3
4 <head>
5 <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
6 <title>IE7关闭窗口时总是提示的解决办法</title>
7 </head>
8
9 <body>
10
11 <!--以下均支持IE6和IE7、IE8,不支持Firefox2.0,其他浏览器未经测试-->
12 <script type="text/javascript">
13 function CloseWin()
14 {
15 window.opener=null;
16 window.open("","_self");
17 window.open("","_self");window.open("","_self");window.close();
18 }
19 </script>
20 <a href="javascript:CloseWin();">点击这里无提示关闭当前窗口</a>
21 </body>
22
23 </html>
2 <html xmlns="http://www.w3.org/1999/xhtml">
3
4 <head>
5 <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
6 <title>IE7关闭窗口时总是提示的解决办法</title>
7 </head>
8
9 <body>
10
11 <!--以下均支持IE6和IE7、IE8,不支持Firefox2.0,其他浏览器未经测试-->
12 <script type="text/javascript">
13 function CloseWin()
14 {
15 window.opener=null;
16 window.open("","_self");
17 window.open("","_self");window.open("","_self");window.close();
18 }
19 </script>
20 <a href="javascript:CloseWin();">点击这里无提示关闭当前窗口</a>
21 </body>
22
23 </html>
posted on 2010-09-18 15:16 skind@126.com 阅读(73) 评论(0) 收藏 举报

浙公网安备 33010602011771号