• I have a website that was hacked, Network Solutions shut it down and required the removal of all .php files. So I chose to delete all files and reinstall WordPress.

    For the database, it is of course already created and I assume it would have some bad hacked content in it.

    So can I just empty all existing tables and then install a fresh copy of WordPress? Or do you suggest something else?

    Thanks!

    Jeff

Viewing 4 replies - 1 through 4 (of 4 total)
  • Why not just start with a fresh new database?

    Thread Starter Jeffkan1

    (@jeffkan1)

    I see, just create a new database, go from there. Makes sense, thanks.

    You’re welcome.

    First do you have a known good database backup taken from before the hack? If there is not a good backup, you will loose everything by dumping the database. Regardless of a backup, I would not do anything to your existing database. It may be damaged but it may also be all you have left of your site.

    If there is a good database backup, I would build a fresh install including a new database. Your host probably has a one button WordPress set up. After the install you can import the database backup. And you should have your site back.

    If there is no database backup, I would still use the one button installation. Then you will have some options. You could change the database credentials in wp-config.php to your old settings. If your old config file is gone and you have no record of the old database name, user and password, you can change those to something you do know using your hosting account.

    At this point you would have a live site with your old content but a possibly hacked database. You could attempt to clean the old database or you could choose Tools > Export > All Content and create an XML file of your old site. Then reconnect your new database and import the XML file into your new site. Either way, you should have your old site content back.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘WordPress database and a hacked website’ is closed to new replies.