0

There is an error that solve with some refresh.

What is the problem? (I have already set royalshoe into config/database)

Error:

Unable to select the specified database: royalshoe

Filename: C:\xampp\htdocs\royalshop\system\database\DB_driver.php

Line Number: 140
4
  • have you auto loaded database and set database settings correct. It also could be something wrong in your code not matching the db table but unsure because need to see your controller / model where error comes from. Commented Mar 5, 2015 at 15:17
  • see this question: stackoverflow.com/questions/15503757/… Commented Mar 5, 2015 at 15:18
  • I think the problem occur due to xamp Commented Mar 5, 2015 at 15:21
  • please provide your controller and model in order for us to help you Commented Mar 5, 2015 at 17:17

1 Answer 1

2

If you are using XAMPP you first need to run SQL admin (to access phpAdmin panel), then ALWAYS create a database and then load it from file (your database name.sql). Make sure you never load a database in phpAdmin without creating one first.

Once you've done that, make sure all config files (such as database.php and DB_driver.php) are configured correctly for the right database name.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.