• Mau

    (@mauricio-gouvea)


    Hello everyone!

    I’ve changed the wp-config.php file (by mistake) from a client’s website. This website was made by other person and I don’t have a backup. I contacted the host provider that was able to put the website online again, but, for somehow, the content is different, images are not loading… it’s a mess. I haven’t deleted anything. The only change was on this wp-config.php file. Is it possible to recover the last version of this website?

    PS:
    1. When I open the media library I can’t see the images, but they are there (I see on ftp).

    2. There’s a “temp” on the url’s. I don’t recall to see this word before.

    • This topic was modified 4 years, 1 month ago by Mau.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    >> Is it possible to recover the last version of this website? <<

    Unless you backed it up, no. Check with the host to see if they have any backups.

    In addition to what Steven has said, do you remember specifically what you changed?

    Thread Starter Mau

    (@mauricio-gouvea)

    UPDATE: The hostgator support was able to remove the “/temp” from the url, but the images are still not loading.

    Thread Starter Mau

    (@mauricio-gouvea)

    In addition to what Steven has said, do you remember specifically what you changed?

    I changed the DB_NAME, DB_USER and DB_PASSWORD fields. I created a “v2″folder and I was about to do a fresh install to create the new version of this clients website, but, unfortunately, I uploaded this file to the wrong folder and overwrote the wp-config file of the present website.

    I don’t have a backup of this website, but I have a doc file with the wp-config information of theses fields (DB_NAME, DB_USER and DB_PASSWORD). I made the changes and uploaded the file again, but it didn’t work as planned.

    You might create a new config file from the default sample wp-config file by manually adding the proper data from your ‘doc file’ if those are correct and then working through the ‘broken’ file and that new config to recover what you can.

    But double-check with Hostgator to make sure they don’t have a backup. And I’d FTP into that site (or use the control panel’s file manager) looking for backup files. There’s often a backup snapshot somewhere the host made or someone else made.

    Don’t forget, your test site may have a different htaccess file which may have been overwritten.

    You might also want to bring the site up with all plugins disabled and a generic theme like Twenty Seventeen while you fix what you can with the database you have. That’s how I do recoveries like this when necessary. That puts all the ‘variables’ out where they can be seen by using nothing but a generic theme.

    If you have a lot of odd problems you might need to overwrite the WordPress core files or let the errors tell you of problem parts.

    Also, the Wayback Machine may have a recent archive of any missing broken elements… That thing can be a real lifesaver at times.

    Thread Starter Mau

    (@mauricio-gouvea)

    Thanks JNashHawkins,

    We decided to focus on the new version of website. The present website was not fully recovered, but we won’t spend time and energy trying to recover it, since we are starting to develop the new one.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Huge mistake. I’ve edited the wp-config.php’ is closed to new replies.