1

3 weeks ago I uploaded all my files from localhost to cPanel. I want to switch it back , the issue I facing is my original database from the localhost is not updated . I downloaded the database from the cPanel and tried to set it in local host in wp-config.php , but its transferring me to installation every time and then resetting all the data. How can I update the database so it will show the site the same exact way as in production?

0

just to understand you... You have a livesite on some host which uses cpanel and you want to revert it back to your local Installation? (e.g. xamp)

I think the easiest way is to use a Backup/Restore plugin. For example Akeeba Backup (free and easy to use). It also helps you to replace permalinks that may have changed.

0

If you're getting the installation page, it means that you probably have:

  1. Incorrect database name in wp-config.php - Look for DB_NAME in the file. It should match the database name used when you imported it to localhost
  2. Incorrect database table prefix in wp-config.php. Check if $table_prefix is the same on production and on your local

Note: I'm assuming that you already downloaded the database from cPanel and imported it into localhost. You can read the Moving WordPress page on the Codex. Don't forget to update the siteurl and home fields in the options table, else you'll be redirected to the production server.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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