W3C home > Mailing lists > Public > whatwg@whatwg.org > November 2004

[whatwg] handling redirects with XMLHttpRequest

From: Hallvord Reiar Michaelsen Steen <hallvors@online.no>
Date: Fri, 26 Nov 2004 17:05:31 +0100
Message-ID: <41A7625B.13585.207A5495@localhost>
Spec says:
> If the response is an HTTP redirect, then it should be transparently
> followed (unless it violates security or infinite loop precautions)

It does not explicitly state what should happen if these security or 
loop precautions are violated by the redirect.. I checked this in 
Opera and FireFox, the current implementations differ. FireFox will 
"complete" loading and set readyState to 4, but the status will be 
302 or whatever redirection status code was used. Opera never changes 
readyState to 4, so the loading is interrupted silently. FireFox's 
implementation seems cleaner..

Perhaps say:


If the response is an HTTP redirect, then it should be transparently 
followed unless it redirects to an address the UA finds unacceptable 
due to security limitations or infinite loop precautions. In this 
case the UA must complete loading with the current response.


(If that isn't clear enough any rewording is much appreciated, it 
still seems a bit kludgy to me.)
-- 
Hallvord Reiar Michaelsen Steen
http://www.hallvord.com/
Received on Friday, 26 November 2004 08:05:31 UTC

This archive was generated by hypermail 2.3.1 : Monday, 13 April 2015 23:08:20 UTC