Closed Bug 166799 Opened 22 years ago Closed 22 years ago

history operations on pages having iframe within frame have problems in specific case

Categories

(Core :: DOM: Navigation, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.3beta

People

(Reporter: pprerana, Assigned: radha)

References

()

Details

Attachments

(1 file)

Using mozilla1.0 released version (Mozilla/5.0 (Windows; U; Windows NT 5.0;
en-US; rv:1.0.0) Gecko/20020530) installed on Windows2000.

Simplified Test Case is uploaded at: 
http://208.198.42.244/~prerana/iframes/iframe.html

Steps to reproduce:
1. Load the above page. The page is a frameset having 2 frames. The "onload"
script of the frameset sets "location.href" of one frame. This newly loaded page
has an iframe in it. Thus the lower frame will show a page with iframe after
"onload".
2. Click the "Page One" link from the lower frame. This loads "Page one" into
the iframe.
3. "Page one" contains 2 links. Click "go to three" link. This loads "page
three" in the iframe.
4. Go back in history (hit back button of the browser). Observe that iframe is
not shown at all, instead the contents of the frame are replaced by the contents
of iframe. I would expect history to show me the iframe with both links in it. 

The expected behavior is more obvious by observing the difference from IE6.0 or
Netscape6.1(Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:0.9.2)
Gecko/20010726 Netscape6/6.1)
Urk, nasty. Notice that if you try to view the source of the lower frame (with
RightClick / This Frame / View Frame Source) the source of the IFRAME is
displayed. Moz has completely lost track of the nested frames.

Confirming with 20020826 (1.1) on Linux.

Please change Platform/OS to All/All. And it's not just a history problem, it's
a problem with frames, so I'd guess that the Component should be HTMLFrames.
(When you change that, please also choose 'Reassign bug to owner of selected
component'.)
Status: UNCONFIRMED → NEW
Ever confirmed: true
making changes to OS,Platform,Component as specified in "Comment #1".
Assignee: radha → jkeiser
Component: History: Session → HTMLFrames
OS: Windows 2000 → All
QA Contact: claudius → amar
Hardware: PC → All
This really is History.
Assignee: jkeiser → radha
Component: HTMLFrames → History: Session
QA Contact: amar → claudius
Shall try to address it for 1.2 beta.
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla1.2beta
Using the LOAD_NORMAL_REPLACE loadtype takes care of the iframe  loads that
happen in onLoad handlers.
Comment on attachment 103059 [details] [diff] [review]
patch to docshell

sr=rpotts@netscape.com
Attachment #103059 - Flags: superreview+
Comment on attachment 103059 [details] [diff] [review]
patch to docshell

r=adamlock
Attachment #103059 - Flags: superreview+ → review+
Attachment #103059 - Flags: superreview+
>   // we don't want this additional load to get into history, since this
>   // load will automatially happen everytime, no matter how the page is loaded.
>-     loadType = LOAD_BYPASS_HISTORY;
>+     loadType = LOAD_NORMAL_REPLACE;

Not that I know much about what is going on here, but seems to me that this
would make the comment above stale. Could you please update the comment too when
you do this.

Thanks.
Comment on attachment 103059 [details] [diff] [review]
patch to docshell

a=asa for checkin to 1.2 (on behalf of drivers).
Attachment #103059 - Flags: approval+
This is on the 1.2 list and has approval.  It should get checked in some time soon.
This has approval.  If it doesn't get checked in by the early morning tree
closure on Nov 5, 2002 it's going to have to wait until after the branch is cut.
I asked alock or rick to check this in a week ago, but I guess that didn't
happen. I'm hesitant to check this in myself since I don't know the code at all,
and if something goes wrong I'm not a good choice for fixing it...
The clock is ticking.
This has been approved for 1.2 but no one has checked it in.  This is going to
miss the boat soon.
alecf: could you land this on the branch?
done.
Keywords: fixed1.2
Thanks Alec for checking this in to the branch. This still needs to be checked
in to the trunk. 
Target Milestone: mozilla1.2beta → mozilla1.4alpha
Target Milestone: mozilla1.4alpha → mozilla1.3beta
This is fixed in the trunk too. 
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Component: History: Session → Document Navigation
QA Contact: claudius → docshell
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: