PHP Snippet 1:
$autoload['libraries'] = array('session');
PHP Snippet 2:
$config['sess_driver'] = 'database';
$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration'] = 21600;
$config['sess_use_database'] = false;
$config['sess_table_name'] = 'ci_sessions';
$config['sess_match_ip'] = false;
$config['sess_time_to_update'] = 300;
$config['sess_save_path'] = APPPATH . "cache/sessions/";
PHP Snippet 3:
CREATE TABLE `sessions` (
`id` varchar(40) NOT NULL,
`ip_address` varchar(45) NOT NULL,
`timestamp` int(10) UNSIGNED NOT NULL DEFAULT '0',
`data` blob NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=COMPACT;
PHP Snippet 4:
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class MY_Session extends CI_Session {
public function __construct(array $params = array())
{
if ( $this->ignore_sessions() )
return;
parent::__construct();
}
function ignore_sessions()
{
$uri = str_replace ("//", "/", $_SERVER['REQUEST_URI']);
if ( strpos($uri, '/ignore_this_controller/') === 0 )
return true;
return false;
}
}
PHP Snippet 5:
$autoload['libraries'] = array('session')
PHP Snippet 6:
<link rel="manifest" href="manifest.json">
PHP Snippet 7:
<link rel="manifest" href="manifest.json" crossorigin="use-credentials">