|
-
Apr 30th, 2002, 03:45 AM
#1
Thread Starter
Member
How to automatically close window without prompt?
How do I use the window.close() java function without that confirm pompt box coming up?
What I want is: as soon as the user gets to my start page, a popup window is launched (using the window.open() command) and the start page is automatically closed down.
When my start page is loaded, I use a java function I wrote that contains the window.open() command to launch the pop-up. That line of code is followed by wiindow.close(). That works with the pop-up launching but before the main page closes itself, it first presents the user with a kind of "Are you sure?" promt and asks to press "Yes" or "No" to confirm before closing that window. I don't want that promt to come up at all, I just want the main browser window to close unconditionally as soon as the pop-up launches.
Thanks.
-
Apr 30th, 2002, 05:17 AM
#2
Fanatic Member
Hi,
you cant close a window that you haven't opened. Its a security feature on browsers. If they are allowed you to close windows without a prompt some websites would exploit it by closing other browser windows you might have open.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|