class Cookie
Represents a cookie
Methods
|
__construct(string $name, string $value = null, integer|string|DateTime $expire, string $path = '/', string $domain = null, Boolean $secure = false, Boolean $httpOnly = true)
Constructor. |
||
| string |
__toString()
Returns the cookie as a string. |
|
| string |
getName()
Gets the name of the cookie. |
|
| string |
getValue()
Gets the value of the cookie. |
|
| string |
getDomain()
Gets the domain that the cookie is available to. |
|
| integer |
getExpiresTime()
Gets the time the cookie expires. |
|
| string |
getPath()
Gets the path on the server in which the cookie will be available on. |
|
| Boolean |
isSecure()
Checks whether the cookie should only be transmitted over a secure HTTPS connection from the client. |
|
| Boolean |
isHttpOnly()
Checks whether the cookie will be made accessible only through the HTTP protocol. |
|
| Boolean |
isCleared()
Whether this cookie is about to be cleared |
Details
at line 46
public
__construct(string $name, string $value = null, integer|string|DateTime $expire, string $path = '/', string $domain = null, Boolean $secure = false, Boolean $httpOnly = true)
Constructor.
at line 82
public string
__toString()
Returns the cookie as a string.
at line 122
public string
getName()
Gets the name of the cookie.
at line 134
public string
getValue()
Gets the value of the cookie.
at line 146
public string
getDomain()
Gets the domain that the cookie is available to.
at line 158
public integer
getExpiresTime()
Gets the time the cookie expires.
at line 170
public string
getPath()
Gets the path on the server in which the cookie will be available on.
at line 182
public Boolean
isSecure()
Checks whether the cookie should only be transmitted over a secure HTTPS connection from the client.
at line 194
public Boolean
isHttpOnly()
Checks whether the cookie will be made accessible only through the HTTP protocol.
at line 206
public Boolean
isCleared()
Whether this cookie is about to be cleared