Welcome Guest, Not a member yet? Register   Sign In
Autoload database to libraries error

Hello everyone

I'm trying to configure libraries in autoload.php with:

$autoload['libraries'] = array('database', 'session');

but I keep getting this error:

A Database Error Occurred

Unable to connect to your database server using the provided settings.

Filename: C:\wamp\www\ci_series\system\database\DB_driver.php

Line Number: 125

When I remove 'database' from the array it works and I get the CodeIgniter welcome page.

How do I fix this?

Thanks in advance!!

what it tells you is that the settings you provided for the database connection are not correct. You should take a look inside application/config/database.php and see if the server, username, pasword and driver are correct.

Thanks for the reply! It worked after I removed "root" as the password.

Theme © iAndrew 2016 - Forum software by © MyBB