corex/session

This package is abandoned and no longer maintained. No replacement package was suggested.

Session (Namespace, Page, Token, ...)

2.0.0 2018-12-09 19:57 UTC

This package is auto-updated.

Last update: 2023-09-16 10:36:40 UTC


README

License Build Status codecov

Session

Session handler.

A few examples.

// Set session variable.
Session::set('actor', 'Roger Moore');

// Get session variable.
$actor = Session::get('actor');

// Check if session variable exists.
if (!Session::has('actor')) {
}

Token

Token handler (uses Session handler).

A few examples.

// Create csrf token.
$csrfToken = Token::create('csrf');

// Check csrf token.
if (!Token::isValid($csrfToken)) {
}