Skip to content

Kirby 3.6.6

$session->set()

Sets one or multiple session values by key

$session->set(string|array $key, mixed $value = null): void

Parameters

Name Type Default Description
$key * string|array The key to define or a key-value array with multiple values
$value mixed null The value for the passed key (only if one $key is passed)

Parent class

Kirby\Session\SessionData