W3C home > Mailing lists > Public > ietf-http-wg@w3.org > October to December 2008

Re: server applying PUT to a resource other than the request-URI

From: Henrik Nordstrom <henrik@henriknordstrom.net>
Date: Mon, 20 Oct 2008 22:07:17 +0200
To: Julian Reschke <julian.reschke@gmx.de>
Cc: HTTP Working Group <ietf-http-wg@w3.org>
Message-Id: <1224533237.12369.17.camel@henriknordstrom.net>
Sorry. A bit tired. Didn't notice the change to POST.

Switching to POST isn't good either.

I'll second Brians response here.

Additionally allowing for PUT to create a new resoure-URI completely
different from the request-URI would make sense, but needs to be
negotiated by a request header indicating that the client accepts this.

Regards
Henrik

On mån, 2008-10-20 at 22:01 +0200, Henrik Nordstrom wrote:
>  
> > IMHO the *right* thing to do is:
> > 
> > C: PUT /folder/foo
> > C: Host: ...
> > C:
> > C: Content
> > 
> > S: HTTP/1.1 4xx
> > S:
> > S: You can't do that
> 
> 
> Why 4xx. A redirect to the URI where the resource may be stored is more
> appropriate.
> 
> Hmm.. the text in PUT should be fixed as well.. 301 is not a good redirect code to use there due to the amount of broken implementations..
> 
> > and instead
> > 
> > C: POST /folder
> > C: Host: ...
> > C:
> > C: Content
> > 
> > S: HTTP/1.1 201 Created
> > S: Location: /folder/bar
> 
> No. See above.
> 
> REgards
> Henrik

Received on Monday, 20 October 2008 20:08:03 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 27 April 2012 06:50:56 GMT