SAMESITE_LAX
SAMESITE_LAX = 'lax'
Represents a cookie.
__construct(string $name, string|null $value = null, integer|string|\DateTimeInterface $expire, string $path = '/', string|null $domain = null, boolean $secure = false, boolean $httpOnly = true, boolean $raw = false, string|null $sameSite = null)
string | $name | The name of the cookie |
string|null | $value | The value of the cookie |
integer|string|\DateTimeInterface | $expire | The time the cookie expires |
string | $path | The path on the server in which the cookie will be available on |
string|null | $domain | The domain that the cookie is available to |
boolean | $secure | Whether the cookie should only be transmitted over a secure HTTPS connection from the client |
boolean | $httpOnly | Whether the cookie will be made accessible only through the HTTP protocol |
boolean | $raw | Whether the cookie value should be sent with no url encoding |
string|null | $sameSite | Whether the cookie will be available for cross-site requests |