Welcome Guest, Not a member yet? Register   Sign In
Controller within Controller Issue
#1

Hey,

In CodeIgniter 2.2.0 I was able to create a Controller object inside a Controller. In CodeIgniter 3.0.0-develop I am no longer able to do this because I get the error message: "Unable to locate the specified class: Session.php". Am I missing something? Here is my setup.

1) autoloader.php:
PHP Code:
$autoload['drivers'] = array(
 
   'session'
); 

2) config.php:
PHP Code:
$config['sess_driver']            = 'native';
$config['sess_valid_drivers']    = array();
$config['sess_cookie_name']        = 'bbp_user_sessions'// Custom class.
$config['sess_expiration']        = 21600              // 6 hours
$config['sess_expire_on_close']    = FALSE;
$config['sess_encrypt_cookie']    = TRUE               // Use security
$config['sess_use_database']    = TRUE               // Use database
$config['sess_table_name']        = 'bbp_user_sessions';
$config['sess_match_ip']        = FALSE;
$config['sess_match_useragent']    = TRUE;
$config['sess_time_to_update']    = 300

3) bbp_user_sessions table
Code:
CREATE TABLE `bbp_user_sessions` (
 `session_id` varchar(40) NOT NULL DEFAULT '0',
 `ip_address` varchar(45) NOT NULL DEFAULT '0',
 `user_agent` varchar(120) NOT NULL,
 `last_activity` int(10) unsigned NOT NULL DEFAULT '0',
 `user_data` text NOT NULL,
 PRIMARY KEY (`session_id`),
 KEY `last_activity_idx` (`last_activity`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
Reply


Messages In This Thread
Controller within Controller Issue - by Hideauze - 01-12-2015, 05:13 PM
RE: Controller within Controller Issue - by Narf - 02-04-2015, 05:47 PM



Theme © iAndrew 2016 - Forum software by © MyBB