Learn R Programming

cookiemonster (version 0.1.0)

delete_cookies: Delete Cookies

Description

Delete Cookies

Usage

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

Value

Nothing. Called to remove cookies from jar.

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.

Examples

Run this code
# 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)

Run the code above in your browser using DataLab