• Resolved Kapag

    (@kapag)


    Hi,
    Am quite a new user to WordPress, and have been learning as I go at work helping to redevelop our website.
    Due to being inexperienced, I do a lot of experimentation with pieces of coding and it sometimes goes wrong and the site goes down. Whenever this happens, I would usually use BTs built in restore service, which restores the files stored by them to a couple of hours ago, and this corrects the problem.
    Today I was adding some code into the sidebar.php file, and when I saved it the site went down. This has happened before so I tried to restore the site to a couple of hours ago, but it did not fix the problem. (It is important to note that at the same time we were also installing an SSL certificate onto the site, so this could also have caused the problem, but I am assuming it is the coding) I contacted BT to ask why this was, and was informed that I should use our backup of the site to restore the files and fix the issue.
    We have started this process, and now when trying to access the site the error message ‘Error establishing a database connection’ appears. I have since learned that we should be keeping a backup of both the files and of the database, which we do not have. Unfortunately BT did not tell us what areas we needed to backup and due to inexperience we assumed that backing up the files was enough.
    Any help or advice would be very greatly appreciated as I currently do not see how we would be able to get the site back at present, which is a major issue as the site contains ALOT of information which has been manually entered.
    Thankyou.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Double-check the wp-config.php file to ensure that the database connection details, including the table prefix, are correct.

    If they are, contact your hosting provider to ask why the database server is offline.

    Thread Starter Kapag

    (@kapag)

    Is this the wp-config.php file within the wp-content folder? Or the wp-config-sample.php file?

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    It shouldn’t be in the wp-content folder, unless you purposefully moved it, but check it anyway. Definitely not the -sample one though.

    Thread Starter Kapag

    (@kapag)

    Thankyou so much, I deleted the wp-config.php file that was in the wp-content folder and it has fixed the issue (no idea how it got there).
    You have saved me, thankyou 🙂

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    You’re welcome!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Site Down, Restore Not Working, No Database Backup’ is closed to new replies.