"window names" for window.open / target are not global (multiple windows can have the same name)




12 years ago
9 years ago


(Reporter: aaron_liebling, Unassigned)


2.0 Branch
Windows XP

Firefox Tracking Flags

(Not tracked)


(Whiteboard: [CLOSEME 5-15-2010])



12 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20070309 Firefox/
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20070309 Firefox/

Window names do not seem to be universal, but instead are only recognized by the original opening window and its children.


sites a, b and c all have links to one another (each link opening the respective site in a window of the same name.  If site a is open and the user opens both sites b and c and then tries to open site b from site c, two site b windows (both with the name "b") will now exist: the one originally opened by site a and the one opened from site c.

Expected behaviour: the site b opened from site c should have open ed in the existing window named "b" which was opened from site a.

Note: this is happened across sites (different hosts).  I have not checked to see if the behaviour is identical within a site.

Reproducible: Always

Steps to Reproduce:
1. Have a site A with links to two other sites.  These links use javascript window.open() to open other sites in uniquely named windows (B & C).
2. Click on one of the links to open site B in window B.
3. Click on the other link to open site C in window C.
4. Site C has a link which uses javascript window.open to open site B in window B.  click on this link.  
Actual Results:  
A seconds instance of site B will now be opened.  There will now be two windows both named "B".

Expected Results:  
The link should have caused site B to open in the existing window B.

It looks like windows are only aware of the names of their children and their children's children in a tree hierarchy (one way down).  They have no awareness of windows opened by their parent or other windows.  

Again, this may be a specifically cross-site (different host) problem.

this problem does NOt occur with any other browser (safari, IE6, IE7).

Comment 1

12 years ago
I think this is intentional and I'm surprised other browsers don't do the same thing.  But maybe it's only intentional for frames (see bug 103638 and bug 273699)?
Summary: Window names not universal (multiple windows with the same name being opened by javascript → "window names" for window.open / target are not global (multiple windows can have the same name)

Comment 2

12 years ago
While it makes total sense for frames, it makes far less sense for multiple windows (where having global unique names can be very important).

I definitely think this is worth addressing.
This bug was reported on Firefox 2.x or older, which is no longer supported and will not be receiving any more updates. I strongly suggest that you update to Firefox 3.6.3 or later, update your plugins (flash, adobe, etc.), and retest in a new profile. If you still see the issue with the updated Firefox, please post here. Otherwise, please close as RESOLVED > WORKSFORME
Whiteboard: [CLOSEME 5-15-2010]
Version: unspecified → 2.0 Branch
No reply, INCOMPLETE. Please retest with Firefox 3.6.x or later and a new profile (http://support.mozilla.com/kb/Managing+profiles). If you continue to see this issue with the newest firefox and a new profile, then please comment on this bug.
Last Resolved: 9 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.