FindCookies

FindCookies[]

gives a list of all currently set cookies.

FindCookies[domain]

gives a list of cookies associated with the specified domain.

FindCookies[assoc]

gives a list of cookies whose attributes match the specification in the association assoc.

Details

  • FindCookies[] is equivalent to $Cookies.
  • FindCookies returns a list of associations representing the cookies it has found.
  • In FindCookies[domain], domain can be either a string or a string pattern of the type used in FileNames.
  • FindCookies[domain] is equivalent to FindCookies[<|"Domain"->domain|>].
  • In FindCookies[assoc], the association can contain entries with any of the following keys, with the same possible values as in $Cookies:
  • "Domain"domain for the cookie
    "Path"path restriction within the domain
    "Name"name of the cookie
    "Content"content of the cookie
    "ExpirationDate"when the cookie is set to expire
    "CreationDate"when the cookie was created
    "AllowSubdomains"whether to send cookies to subdomains (HostOnly)
    "ConnectionType"for what connection type the cookie should be sent (Secure)
    "ScriptAccessible"whether cookie is accessible from JavaScript etc. (HttpOnly)

Examples

open allclose all

Basic Examples  (1)

Cookies are received and set when URL commands are executed:

Find all cookies:

Find cookies by domain:

Find cookies with a specified name:

Find cookies with an expiration date of Automatic:

Find cookies with explicit expiration dates:

Properties & Relations  (1)

FindCookies[] returns all cookies present in $Cookies:

Wolfram Research (2016), FindCookies, Wolfram Language function, https://reference.wolfram.com/language/ref/FindCookies.html.

Text

Wolfram Research (2016), FindCookies, Wolfram Language function, https://reference.wolfram.com/language/ref/FindCookies.html.

CMS

Wolfram Language. 2016. "FindCookies." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/FindCookies.html.

APA

Wolfram Language. (2016). FindCookies. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/FindCookies.html

BibTeX

@misc{reference.wolfram_2024_findcookies, author="Wolfram Research", title="{FindCookies}", year="2016", howpublished="\url{https://reference.wolfram.com/language/ref/FindCookies.html}", note=[Accessed: 24-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_findcookies, organization={Wolfram Research}, title={FindCookies}, year={2016}, url={https://reference.wolfram.com/language/ref/FindCookies.html}, note=[Accessed: 24-November-2024 ]}