window.open(url, target) does not open url in iframe "target" if page is not in active tab

RESOLVED WORKSFORME

Status

defect
RESOLVED WORKSFORME
16 years ago
11 years ago

People

(Reporter: lutz.petersen, Assigned: jag+mozilla)

Tracking

Trunk
x86
Windows 2000
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.0; de-AT; rv:1.3) Gecko/20030312
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; de-AT; rv:1.3) Gecko/20030312

Consider a document that uses JavaScript to load some URL into a frame already
existing in that document. The JavaScript would use the window.open(url, target)
method to achieve that. Now, everything works fine without tabbed browsing.
However, consider the following case: You have opened two tabs, one tab (#1)
with the document using the JavaScript described above, and another one (#2)
displaying a simple document (no frames). When the JavaScript is executed while
tab #2 is active, the URL is not loaded into the frame provided by tab #1, but a
new window is opened.

Reproducible: Always

Steps to Reproduce:
1. Open http://abi00.virtualave.net/test.html in a new tab (#1).
The page repeatedly calls window.open('frame.html', 'frame') to load
"frame.html" into the iframe named "frame".
2. Verify that frame.html is correctly loaded into the iframe on that page.
3. Open a new tab (#2) and activate it.
Actual Results:  
frame.html is not any more loaded into the iframe, but a new window is opened.

Expected Results:  
frame.html should still be loaded into the iframe.
can you try again with 1.4RC3 ?
Problem persists in 1.4 build 20030624.
Might be related to bug 121377.
Assignee: dom_bugs → jaggernaut
Status: UNCONFIRMED → NEW
Component: DOM Level 0 → Tabbed Browser
Ever confirmed: true
QA Contact: ashishbhatt → pmac
Summary: window.open(url, target) does not open url in pre-existing frame "target" while using tabbed browsing → window.open(url, target) does not open url in iframe "target" if page is not in active tab
*** Bug 218300 has been marked as a duplicate of this bug. ***
*** Bug 201212 has been marked as a duplicate of this bug. ***
Posted file test case, file #1
Posted file test case, file #2
Uploaded test case files, as the source mentioned in original description is not
available anymore. Download both files, and open file #1 to see a demonstration
of the bug.
How is this bug now that Bugzilla Bug 266299
browser.link.open_newwindow.restriction should have a default value of 2 is fixed?
Worcester, just because we set the default pref. to a different value doesn't mean the bug disappears.
(In reply to comment #10)
> Worcester, just because we set the default pref. to a different value doesn't
> mean the bug disappears.
> 

I realize that. I was hoping that maybe this in turn would make the fix easier or at least point out to people here that the fix happened. Hope that cleared up what I intended to say above.
The testcases in this bug work fine for me, with all values of the prefs.  Marking so.
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → WORKSFORME
Product: Core → SeaMonkey
You need to log in before you can comment on or make changes to this bug.