Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3984830
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T05:49:03+00:00 2026-05-20T05:49:03+00:00

I downloaded the last version of CodeIgniter and I tried to run a simple

  • 0

I downloaded the last version of CodeIgniter and I tried to run a simple app. The code works perfectly without database, but when I added this

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

the page went to blank.

I looked at the logs files but I didn’t find anything, I check differents tutorial, but my database.php file looks correctly configured. I removed it from the array.

$autoload['libraries'] = array('');

and added to the controller this:

$this->load->library('database'); 

Then, this error appeared

An Error was encountered

Unable to load the requested class: database

What I do? Any clue?

Thanks in advance

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T05:49:03+00:00Added an answer on May 20, 2026 at 5:49 am

    To use the database you need to use the ‘library’ autoload instead of the ‘config’ auto load

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

    This will actually automatically load up your configurations.

    UPDATE

    Another thing you mention in your question is that you ‘add’ that line, you do not need to add that line, you are suppose to add the element to the array that already exists on that line. You potentially could be overwriting other autoloaded libraries, I will need to see your autoload.php file to confirm this.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I downloaded the last version of jScrollPanel (2.0 beta 5) but when opened jquery.jscrollpane.css
I downloaded and installed the Aptana Studio free version. But apparently, to install the
I'm using the Django Registration class, it's great, but the last version shipped with
Am I doing something incorrectly with this? My app went out last night, but
I've downloaded Eclipse Classic 3.5 Galileo, the last version of Android SDK, downloaded and
I downloaded the package http://nodebox.net/code/index.php/Linguistics#verb_conjugation I'm getting an error even when I tried to
I downloaded symfony2 and I am able to run it starting from app_dev.php. But
Clicking through to the download-page if see that the last version of the download
I downloaded Reflector.Net and it's an .Exe outside VS. I remember (last year) when
I'm installing the last version of MediainfoDLL on Fedora 8/9 64bits ( http://mediainfo.sourceforge.net/es/Download/Fedora ).

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.