Last week while I was doing some spring cleaning, I decided to move a few of my sites over to a new CPanel. The move went fairly smoothly, but once everything was moved, there was the matter of updating the WordPress database to show the new database name. If you are wanting to do something similar, here is what you need to do.
All you need to do is update the wp-config.php file to point towards the new database name, which should be found in the root of your WordPress installation. Open the wp-config.php file and look for the following code:
Where it says dbname, update the name of your database. If your login name changed, you’ll want to update that as well.
Once that was done, the only problem I encountered was that I was unable to upload pictures. The fix? Go into your WordPress dashboard and go to Settings –> Miscellaneous and update the path where images are uploaded to.