Sessions
IssuesphpPHP simplifies the use of sessions through a set of classes.
use Issues\Session\Session;
Set Session
Let's look at how to set a global session variable.
Session::set($key, $value);
Get Session
Obtain the value as follows.
Session::get($value);
Remember to initiate the session at the top level of your project scope.
Session::init();
Delete Session
Delete a session variable.
Session::delete($key);
Destroy Session
Destroy all sessions in our application.
Session::destroy();