W3C home > Mailing lists > Public > public-webapps@w3.org > July to September 2010

Re: [XHR] Redirects

From: James Leigh <james-nospam@leighnet.ca>
Date: Mon, 13 Sep 2010 11:51:26 -0400
To: Anne van Kesteren <annevk@opera.com>, Darin Fisher <darin@chromium.org>
Cc: WebApps WG <public-webapps@w3.org>
Message-ID: <1284393086.2107.14.camel@james-laptop>
On Wed, 2010-09-01 at 01:03 -0700, Darin Fisher wrote: 
> 
> I thought of another reason to want the original XHR object to be
> responsible for following the redirect:  the value of a Location
> header may be a relative URL.  It would be nice if application authors
> did not have to take care of resolving that manually.  (In the case of
> a cross-origin request, the relative URL should be resolved relative
> to the URL that was redirected instead of against the Document.)  This
> seems like something that could be easy to mess up.
> 
> 
> -Darin


I want to point out that resolving the Location header is not specific
to 3XX responses. A 201 (Created) response also includes a Location
header that may need to be resolved. If the problem of providing a way
to resolve redirect is addressed it might be good to also address the
problem of resolving 201 locations as well.

One suggestion might be to provide a getResponseLocation() that returns
the resolved Location header.

James
Received on Monday, 13 September 2010 15:52:13 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:40 GMT