I recently moved a Joomla site to a new server, and for some reason the front end only gives a DB error:

0 - Could not connect to MySQL.

This is usually due to wrong DB connection details in configuration.php, but the administrator area works perfectly, with no error messages, so I'm sure the DB details are correct.

The site is running Joomla 3.6.0 on Apache with PHP 5.5.31.

There where some file permission problems at first, and although everything is writable now according to Joomla system information, I assume this has something to do with permissions, but I'm at a loss for where to start looking.

Has anyone had similar issues?

1 Answer 1


Are you getting the white screen with the message for the sql, or the Joomla system page with the outdated links etc?

  • I would make sure the restoration on the new server has been done without errors. I mean, it can be some corrupted files.

  • If it's a site that you have built, then you know about what extensions you are using, but just in case make sure there is no extension that is being called in the front-end that needs to have credentials to connect to the database.

  • Clean cache folders, double check configuration file, disable htaccess, check for any other scripts that might try to connect to the database.
  • Spot on! It was a custom extension that required access to a secondary database, and the connection details where not updated. Thanks for your suggestions, those where great ideas based on the little information I gave...
    – johanpw
    Commented Jul 18, 2016 at 14:59
  • Glad if I helped... cheers @johanpw
    – FFrewin
    Commented Jul 18, 2016 at 16:03

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.