• Resolved tasteofscan

    (@tasteofscan)


    I’m getting a “Error establishing a database connection” when trying to log in to my site.

    I read I should access the wp-config.php file but I cannot:

    Error: Failed to open “C:\wp-config.php” for writing
    Error: File transfer failed

    What do I do now? I am totally out of my league here. I’m surprised I have gotten this far (getting access to ftp).

    Berit
    http://www.väljahälsa.se

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

    (@macmanx)

    You’ll need to access the wp-config.php file on your server via FTP or SFTP, not a file on your computer.

    Once you have access, make sure that the database connection details are correct. If they are, you’ll need to contact your hosting provider to find out why your database server is offline.

    Thread Starter tasteofscan

    (@tasteofscan)

    I thought I did access through FTP. I’m using Filezilla and I’m able to log in.
    I get “failed to open” on everything in public_html where the wp-config is located.

    I don’t think I have anything on the computer. Never used FTP before. Always worked on the site while online.

    Moderator keesiemeijer

    (@keesiemeijer)

    Hi tasteofscan

    Try editing the file by using the file manager provided in your host’s control panel.
    more about file managers

    This seems like it’s a permissions issue.
    http://codex.ww.wp.xz.cn/Changing_File_Permissions

    Can you download other files with Filezilla?
    If so ask your host if they have some restrictions for the wp-config.php file.

    Moderator keesiemeijer

    (@keesiemeijer)

    I think you’re downloading the file to a read-only directory on your computer.

    Select a different directory to download to on your computer. Try your documents or downloads folder.

    Thread Starter tasteofscan

    (@tasteofscan)

    I changed the dir to documents and I was able to download the wp-config file but I don’t have a program that can open it.
    What should I use?

    Moderator keesiemeijer

    (@keesiemeijer)

    See: http://codex.ww.wp.xz.cn/Editing_Files#Using_Text_Editors

    Free text editor for Windows: Notepad++
    Free text editor for For Mac: TextWrangler

    Thread Starter tasteofscan

    (@tasteofscan)

    Thank you! I got Notepad++ and Filezilla to work together. Now I can try to deal with the original problem I am having “Error establishing a database connection.” But that is a new topic…

    Moderator keesiemeijer

    (@keesiemeijer)

    You’re welcome. And good luck.

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Cannot access anything public_html incl wp-config.php’ is closed to new replies.