delete_cookies: Delete Cookies

View source: R/delete.r

delete_cookiesR Documentation

Delete Cookies

Description

Delete Cookies

Usage

delete_cookies(
  domain,
  key = "",
  jar = default_jar(),
  fixed = FALSE,
  ask = TRUE
)

Arguments

domain

The domain for which the cookies should be deleted.

key

An optional filter to retrieve only certain cookies by matching certain keys/names. Accepts regular expression depending on the value of fixed.

jar

A character string of the path to the cookie jar (the default is to use default_jar() to get a suitable directory).

fixed

If TRUE, domain and key are matched as is. If either domain or key, only those values are treated as is.

ask

A logical value indicating whether the user should be asked to confirm the deletion.

Value

Nothing. Called to remove cookies from jar.

Examples

# to conform with CRAN policies, examples use a temporary location. Do not use
# the options like this, except you want your cookies gone when closing R.
options(cookie_dir = tempdir())

add_cookies(cookiefile = system.file("extdata", "cookies.txt", package = "cookiemonster"))
delete_cookies("example.com", ask = FALSE)

cookiemonster documentation built on May 29, 2024, 8:12 a.m.