开发者

avoid the confirm dialog box when trying to close IE popup

How to avoid the confirm dialog box “the web page 开发者_C百科you are viewing is trying to close the window” when trying to close IE popup?


Make sure the window you are trying to close is one you opened with JavaScript, and not the one the user arrived at your site with (complete with history they might want to go back through).


This hack used to work in IE, but not sure if it still does:

window.opener = window;
window.close();
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜