Cookie
in package
Tags
Table of Contents
Constants
- RESERVED_CHARACTERS = ["\t", "\n", "\v", "\f", "\r", "\x0e", ' ', ',', ';', '=']
Properties
- $domain : string|null
- $expiry : DateTimeInterface|null
- $httpOnly : bool
- $maxAge : int
- $name : string
- $path : string|null
- $sameSite : string|null
- $secure : bool
- $value : string
Methods
- __construct() : mixed
- __toString() : string
- withDomain() : static
- withExpiry() : static
- withHttpOnly() : static
- withNameAndValue() : static
- withPath() : static
- withSameSite() : static
- withSecure() : static
Constants
RESERVED_CHARACTERS
public
mixed
RESERVED_CHARACTERS
= ["\t", "\n", "\v", "\f", "\r", "\x0e", ' ', ',', ';', '=']
Properties
$domain
protected
string|null
$domain
= null
$expiry
protected
DateTimeInterface|null
$expiry
= null
$httpOnly
protected
bool
$httpOnly
= false
$maxAge
protected
int
$maxAge
= 0
$name
protected
string
$name
$path
protected
string|null
$path
= null
$sameSite
protected
string|null
$sameSite
= null
$secure
protected
bool
$secure
= false
$value
protected
string
$value
Methods
__construct()
public
__construct(string $name[, string|null $value = null ]) : mixed
Parameters
- $name : string
- $value : string|null = null
__toString()
public
__toString() : string
Return values
stringwithDomain()
public
withDomain(string|null $domain[, bool|null $punycode = null ]) : static
Parameters
- $domain : string|null
- $punycode : bool|null = null
Tags
Return values
staticwithExpiry()
public
withExpiry(DateTimeInterface|DateInterval|int|null $expiry) : static
Parameters
- $expiry : DateTimeInterface|DateInterval|int|null
Tags
Return values
staticwithHttpOnly()
public
withHttpOnly(bool $httpOnly) : static
Parameters
- $httpOnly : bool
Tags
Return values
staticwithNameAndValue()
public
withNameAndValue(string $name, string $value) : static
Parameters
- $name : string
- $value : string
Tags
Return values
staticwithPath()
public
withPath(string|null $path) : static
Parameters
- $path : string|null
Tags
Return values
staticwithSameSite()
public
withSameSite(string|null $sameSite) : static
Parameters
- $sameSite : string|null
Tags
Return values
staticwithSecure()
public
withSecure(bool $secure) : static
Parameters
- $secure : bool