I have got a page which has a link pertaining to a close window function.

The window.close() function works perfectly fine in the case of IE based browsers , however it fails to respond on a Mozilla browser(working on tab panes) . I have tried to make use of self.close(), document.close , but there has been no progress.

I have also tried the following code , but have not been successful

MyWindow = window.open('','_parent','');


 MyWindow.close();

Recommended Answers

All 2 Replies

Funny I just posted similar code in another post:

Massage as needed:

//Response.Write("<script>javascript:var w = window.open('clickonce.application','_blank');
w.opener=null;
w.open('','_self');
w.close();
window.open('','_self');
window.opener=null;
window.close();</script>");

I tried your code , But its not working in Mozilla!
I use Mozilla 2.0.0.12
It works perfectly fine in IE , nut I need it to work in both browsers

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.