Method: s::set

Sets a session value by key

Info

Syntax

s::set($key, $value=false)

Parameters

Example


s::set('username', 'bastian');
// saves the username in the session

s::set(array(
    'key1' => 'val1',
    'key2' => 'val2',
    'key3' => 'val3'
));
// setting multiple variables at once