PHP code example of joem / session
1. Go to this page and download the library: Download joem/session library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
joem / session example snippets
// Set an index
session()->set('name', 'Joe');
// Get an index
session()->get('name');
// Get an index with a default return type if the index does not exist
session()->get('name', 'Name not found');
// See if an index exists
session()->has('name');