Skip to content

Latest commit

 

History

History
34 lines (25 loc) · 1.37 KB

README.md

File metadata and controls

34 lines (25 loc) · 1.37 KB

session

Latest Stable Version Total Downloads License build status Code Coverage Scrutinizer Code Quality

A reasonably secure session manager for PHP

Installation

Use composer:

composer require delboy1978uk/session

Usage

use Del\SessionManager;

// Starting the session - also takes a name argument
SessionManager::sessionStart();

// Setting a variable
SessionManager::set('name', 'DelBoy');

// Check a session variable exists
$hasName = SessionManger::has('name');

// Getting a variable
$name = SessionManger::get('name');

// Unsetting a variable
SessionManager::destroy('name');

// Ending the session
SessionManager::destroySession();