Cookie
class Cookie implements ArrayAccess (View source)
Set values of an cookie.
Implements ArrayAccess for backwards compatibility.
Properties
protected array | $cookie |
Methods
No description
No description
No description
No description
The path the cookie is visible to. Defaults to "/" if omitted.
No description
The domain the cookie is visible to. Defaults to the current browsing context's document's URL domain if omitted.
No description
The cookie's expiration date, specified in seconds since Unix Epoch.
No description
Whether this cookie requires a secure connection (https). Defaults to false if omitted.
No description
Whether the cookie is an HTTP only cookie. Defaults to false if omitted.
No description
No description
No description
No description
No description
No description
No description
No description
Details
__construct(string $name, string $value)
No description
static Cookie
createFromArray(array $cookieArray)
No description
string
getName()
No description
string
getValue()
No description
setPath(string $path)
The path the cookie is visible to. Defaults to "/" if omitted.
string|null
getPath()
No description
setDomain(string $domain)
The domain the cookie is visible to. Defaults to the current browsing context's document's URL domain if omitted.
string|null
getDomain()
No description
setExpiry(int $expiry)
The cookie's expiration date, specified in seconds since Unix Epoch.
int|null
getExpiry()
No description
setSecure(bool $secure)
Whether this cookie requires a secure connection (https). Defaults to false if omitted.
bool|null
isSecure()
No description
setHttpOnly(bool $httpOnly)
Whether the cookie is an HTTP only cookie. Defaults to false if omitted.
bool|null
isHttpOnly()
No description
array
toArray()
No description
offsetExists($offset)
No description
offsetGet($offset)
No description
offsetSet($offset, $value)
No description
offsetUnset($offset)
No description
protected
validateCookieName(string $name)
No description
protected
validateCookieValue(string $value)
No description