Dynamically created iframe added to history list of the parent window

RESOLVED DUPLICATE of bug 237717

Status

()

Core
Document Navigation
RESOLVED DUPLICATE of bug 237717
14 years ago
10 years ago

People

(Reporter: Ken Mori, Unassigned)

Tracking

Trunk
x86
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Reporter)

Description

14 years ago
User-Agent:       Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7) Gecko/20040614 Firefox/0.8

When an iframe is created dynamically:
 var f = document.createElement("iframe");
 document.body.appendChild(f);
The iframe is added into the history list of the parent frame.  Refreshing the 
browser will present the page in the dynamically created iframe within the 
parent frame.

Reproducible: Always
Steps to Reproduce:
1.Create a dynamic iframe via JavaScript
2.Refresh main page
3.

Actual Results:  
Page from iframe is displayed rather than the main page

Expected Results:  
The main page should be displayed
Created attachment 151560 [details]
Append iframe to document testcase

I don't see exactly your problem with this testcase, but after I clicked on the
button "x" times and then did a reload, I got "x" items added to the history
list. 
I don't get to see the iframe page however after a reload.
(Reporter)

Comment 2

14 years ago
Created attachment 151564 [details]
Modification to previous attachment demonstrates the problems

Click the "append iframe" button, then click refresh.  Notice the contents of
the iframe take over the main page.
(Reporter)

Comment 3

14 years ago
Seems that the behavior is different if you run via "open file..." than from 
an actual web server.  The problem seems to occur only if run via "open 
file..."
This is fixed on trunk (but not on the 1.7 branch).

*** This bug has been marked as a duplicate of 237717 ***
Status: UNCONFIRMED → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → DUPLICATE

Updated

10 years ago
Component: History: Session → Document Navigation
QA Contact: history.session → docshell
You need to log in before you can comment on or make changes to this bug.