Bug 17598 - FrameLoader should treat all location changes during onload as redirects
Summary: FrameLoader should treat all location changes during onload as redirects
Status: RESOLVED DUPLICATE of bug 42861
Alias: None
Product: WebKit
Classification: Unclassified
Component: Page Loading (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-02-28 16:51 PST by Peter Kasting
Modified: 2010-07-31 15:08 PDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Kasting 2008-02-28 16:51:28 PST
Currently the FrameLoader treats some types of location changes as redirects: meta refresh 0, setting document.location.href (I think this is treated as a redirect at any time, though perhaps it should only be treated as such before/during onload).  Other cases can fall through the cracks, however.  For example, a page that has an onload handler that does a form.submit with a form action that's a different URL to load should be treated as a client redirect, but is not.

I think any location change before/during onload should be treated as a redirect, but the example above is the only concrete case where I know this doesn't happen; maybe there are others.
Comment 1 Brady Eidson 2008-02-28 17:21:23 PST
Interesting.  

Wonder how hard it would be to concoct a series of tests to demonstrate Firefox and even IE's behavior, to compare against WebKit
Comment 2 Peter Kasting 2010-04-29 11:18:50 PDT
abarth has been doing some work on FrameLoader.
Comment 3 Mihai Parparita 2010-07-31 15:08:17 PDT
I've been working on implementing this for my fix for bug 42861. The bug comments have test cases that compare Chrome, Safari, Firefox and IE's behavior in a bunch of scenarios, but briefly, changes to window.location.href up until the onload handler finishes running shouldn't generate a session history entry, but programmatic form submits should (if we want to be consistent with other browsers, the HTML 5 spec is silent on this matter).

*** This bug has been marked as a duplicate of bug 42861 ***