new Session()
Creates a new Session instance
new Session(Kirby\Session\Sessions $sessions, string|null $token, array $options)
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
| $sessionsrequired | Kirby\Session\Sessions |
no default value | Parent sessions object |
| $token | stringornull |
no default value | Session token or null for a new session |
| $optionsrequired | array |
no default value | Optional additional options: - mode: Token transmission mode (cookie or manual); defaults to cookie- startTime: Time the session starts being valid (date string or timestamp); defaults to now- expiryTime: Time the session expires (date string or timestamp); defaults to + 2 hours- timeout: Activity timeout in seconds (integer or false for none); defaults to 1800 (half an hour)- renewable: Should it be possible to extend the expiry date?; defaults to true |