W3C home > Mailing lists > Public > www-talk@w3.org > September to October 2002

Re: Setting cookie and location in the same header

From: Paulo Patricio <pjpatricio@bes.pt>
Date: Tue, 01 Oct 2002 11:58:10 +0100
To: www-talk@w3.org
Cc: Swapna@ariba.com
Message-id: <5.1.1.6.0.20020927124330.00afb378@mail.bes.gbes>

At 11:43 26-09-2002 -0700, you wrote:
>  ...
>
>This gives the following & the Set-Cookie header seems to get lost somewhere
>in the picture.
>
>HTTP/1.1 302 Object Moved
>Location: http://swapnas:8001/aw?awr=
>Server: Microsoft-IIS/4.0
>Content-Type: text/html
>Content-Length: 155
>...

When you set the location response-header  field, you are telling the 
recipient that the requested uri was changed temporally to other location.

ie: the broswer requested http://x.com/xpto.htm
and you change the location to http://y.com/xpto.html

Remember that cookies are related with domains, like someone@lycos.com

So, i think you can't set a cokie on a request to a document that is in a 
different location.
When the recipient request the document at the new uri, and you response 
200 ok. You don't have any problems.

Regards,
Paulo.
Received on Tuesday, 1 October 2002 07:02:03 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 27 October 2010 18:14:27 GMT