start = setInterval(‘CloseWin();‘, 2000); function CloseWin() //这个不会提示是否关闭浏览器 IE6、IE7、FF通用代码: { if (document.readyState == "complete") { try { clearInterval(start); //执行成功,清除监听 window.opener = null; //window.opener=top; window.open("", "_self"); window.close(); } catch (err) { alert(err); } } }
原文:http://www.cnblogs.com/interdrp/archive/2009/10/26/1589944.html
时间: 2024-10-11 13:57:35