开发者

Close Window using javascript in Firefox

I need to close the window on click of a link. I can get it done through window.close() in IE but unable to do the same in Firefox. While googling, I found I have to set the

dom.allow_scripts_to_close_windows property to true to take effect in firefox as well.

Can someone guide me, how and where to set this property to true? I have no idea regarding开发者_如何学编程 that.


You can only close child windows in firefox using javascript. Are you trying to close parent window ?


On URL, you can type:

  1. about:config and press enter.

  2. Accept terms in second window.

  3. You will get list of config entries in that search dom.allow and make it true by double clicking on value column.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜