Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Class 'CI_Driver_Library' not found codeigniter error

I want to use session, so I try to do autoload. In application > config.php, I do $autoload['libraries'] = array('session');

but I got below error

Message: Class 'CI_Driver_Library' not found

Filename: Session/Session.php
like image 638
Alex wood Avatar asked Apr 17 '26 08:04

Alex wood


1 Answers

If your using Codeigniter 3.0 or higher use this:

$autoload['drivers'] = array('session');

Because the session is a driver not a library after version 3.0!

Under Version 2.1 it's a library!

like image 80
Rizier123 Avatar answered Apr 18 '26 20:04

Rizier123



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!