Long COOKIE Question
Posted on 1998-02-19
(1) In the HTTP header (prior to the rest of the HTML doc being sent) using: Set-Cookie: NAME=VALUE; expires=DATE;path=PATH; domain=DOMAIN_NAME; secure
(2) In the header of the HTML Document using:
<meta http-equiv="Set-Cookie" content="NAME=VALUE; expires=DATE; path=PATH; domain=DOMAIN_NAME">
Both presumably amount to the same thing.
Q1. Is this correct. Are both these methods supported by all browsers which support cookie funcionality?
Q2. Does the Set-Cookie header have to be part of a CGI generated HTML page or can it just appear in any HTML page (this really only seems to apply to Set-Cookie format 2 above).
Q3. At what point is cookie actually set. Presumably as soon as the browser receives the header/http-equiv tag?
Q4. Can the information in the cookie be updated? I'm having problems with this. Eg. lets say I want a counter (I don't, but lets say I do). MY_CNT=0001. I want to update this each time using the Set-Cookie: MY_CNT=0002 (etc). Will this actually work? I can't seem to get it to.