View Full Version : Annoying 'Close Window' Box on PC
Phil Marsh
01-08-2001, 05:55 AM
Hi All...
When closing a window with javascript :parent.close(), on the pc an annoying window pops up and says something along the lines of "The browser is trying to close this windows, Yes or No". I have seen other sites open and close windows without this popup box. How can i get rid of it!!!
Thanks in advance...
------------------
Hi, you can only close a window without the alert window using javascript if it has been opened using javascript. Here is some information I have on this subject that I got from who knows where, I hope this will explain things a bit more clearly.
The "close window" alert will not appear if:
The window you're trying to close programmically was opened programmically by your script or your script's document OR
The window you're trying to close is the first document loaded in that window (for example, it was created by a link with a previously-unused target, or all documents have been loaded in the window using location.replace()).
Using Navigator version 4 or later, a signed script with Universal Browser Write privileges can close any window.
Hope this helps you.
Good luck
------------------
Ian
Web Development - BIG Resources Inc
Head Guide - 123Webmaster.com (http://www.123webmaster.com/)
ian@123webmaster.com
BIG Resources.com (http://www.bigresources.com)
ICQ: 25828668
Jason
01-08-2001, 11:16 AM
Moving topic to Client Side Scripting
------------------
Jason M. DesRoches
Co-Founder / Business Development
Big Resources Network (http://www.bigresources.com)
jason@bigresources.com
ICQ: 17947522
vBulletin® v3.6.7, Copyright ©2000-2009, Jelsoft Enterprises Ltd.