Fixing Database Errors Print

  • 8

Fixing Database Errors

Database Error: Unable to connect to the database:Could not connect to database

1. If you are receiving errors on your site that the connection to the database failed, check your configuration.php file in your Joomla directory to make sure it has the correct information. It should be:

var $dbtype = 'mysql';

var $host = 'localhost';

var $user = 'your database username';

var $password = 'your password';

var $db = 'your database name';

var $dbprefix = 'jos_';

404 error - Page not found

These issues can be caused by the search engine friendly URL setup in your Joomla installation. There are a few things you can do to resolve this -

1. Open the configuration.php file and make sure the following line is correct:

var $live_site = ' ';

2. From your admin panel, go to Global Configuration and make sure that both Search Engine Friendly URLs and Use Apache mod_rewrite are set to Yes.

3. Verify you have and index.php file in the Joomla Directory. If there is no file named index (index.php, index.html,etc), the server will not know which page to default to.

Was this answer helpful?

« Back