Open Bug 483386 Opened 15 years ago Updated 2 years ago

javascript:window.close() not closing window

Categories

(Core :: DOM: Core & HTML, defect, P5)

x86
Windows XP
defect

Tracking

()

UNCONFIRMED

People

(Reporter: marun2, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2a1pre) Gecko/20090313 Minefield/3.2a1pre
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2a1pre) Gecko/20090313 Minefield/3.2a1pre

In this page
http://www.aweber.com/form/thankyou_vo.html
(I dont know if it stores cookies or not and it is nota ccessible to other testeers - in that case visit bloggerhigh.com and sign up to get this page. There is a link to "Close this window" which page source shows javascript:window.close(). Doesnt work as expected. Works in IE7. Same page.

Reproducible: Always

Steps to Reproduce:
1. Go to URL http://www.aweber.com/form/thankyou_vo.html
2. If that doesnt work go to bloggerhigh.com and sign up to be taken to this page
3. Click on close window
Actual Results:  
Window not closing

Expected Results:  
Window/tab to close
AFAICT window.close() can only close if the tab/window has been opened from the site with window.open() for security reasons. So INVALID?
It shouldnt matter how the website was coded - IE7 does close the window.
but IE7 does a lot of things that are not standard ;)
And Firefox and all other web browsers are expected to handle non-standard coding - and they do
oh, but even Opera closes the tab. So maybe I'm wrong..
The default settings don't allow it but the user can change the value of the pref dom.allow_scripts_to_close_windows to true if he wants.
http://kb.mozillazine.org/About:config
shouldnt this option be enabled by default? Many sites use javascript window close to close their tabs even when not opened through window open.
Component: General → DOM: Core & HTML
Product: Firefox → Core
QA Contact: general → general
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046

Move all DOM bugs that haven’t been updated in more than 3 years and has no one currently assigned to P5.

If you have questions, please contact :mdaly.
Priority: -- → P5
Severity: trivial → S4
You need to log in before you can comment on or make changes to this bug.