Play around with HTTP cookies and the Set-Cookie HTTP header:
Hint: Open this site in incognito/private browsing mode so that your cookie experiments can be easily reset!
This is:
Visit:
Subdirectories:
Cookies available through JavaScript (document.cookie):
Cookies the client sent in its HTTP request:
Set cookie: Set−Cookie:
Examples (see developer.mozilla.org for a full reference of the Set-Cookie HTTP header):
Set−Cookie: FOO=BAR
Set−Cookie: FOO=BAR; Domain=set-cookie.info
("Only the current domain can be set as the value, or a domain of a higher order, [...]. Setting the domain will make the cookie available to it, as well as to all its subdomains. If omitted, this attribute defaults to the host of the current document URL, not including subdomains. [...] but if a domain is specified, then subdomains are always included." — developer.mozilla.org)