• I recently upgraded a couple of sites to have SSL certificates and static IP addresses. No other changes were made to the sites at all. Since then, I cannot update plugins or WordPress through the backend if using SSL FTP.

    I have my FTP credentials in wp-config.php which has always worked without issue, but now this no longer works if SSL is enabled. (Unable to locate WordPress Content directory (wp-content).) To make matters worse, WordPress and other plugins seem to be overriding my define(‘FTP_SSL’, false); after wp-config has been parsed.

    Setup:
    – Virtual server w/ WHM. I have complete control over the server setup.
    – Not using suExec so FTP credentials are necessary.

    I’ve tried many things:
    – Tried every combination of FTP_HOST (localhost, server static ip, 127.0.0.1, etc)
    – Tried adding the FTP port number to the above
    – Tried every FS_METHOD with varying results, but none work correctly
    – Tried defining FTP_BASE
    – Tried defining FTP_CONTENT_DIR
    – Tried defining FTP_PLUGIN_DIR
    – Tried setting FTP_SSL to false — Had to move this to the end of the wp-config file after the wp-settings.php include because wp-settings was overriding it. This trick worked on one site and not the other. (I’m assuming another plugin is overriding it downstream.)

    Absolutely nothing works to make FTP_SSL work without getting the “Unable to locate WordPress Content directory (wp-content)” message except changing FS_METHOD to “direct” which just causes a host of new errors such as being told the content directory is missing (and then defining that in FTP_CONTENT_DIR), the plugins directory is missing (and then defining that in FTP_PLUGIN_DIR), and then finally being told it cannot create a folder. This is not correct as the FTP_USER has full permissions to read and write the folders in this site.

    Other info:
    – FTP user has full read/write permissions in the folders in question.
    – Base path of the FTP user is the path to the WordPress install.
    – Logging in with Filezilla using TLS over FTP works correctly and shows the correct folder location for the FTP user. All files are accessible.

    So my problems are two-fold:
    1. With FTP over SSL enabled, it simply will not work. WordPress cannot find its wp-content folder.
    2. Disabling FTP over SSL is hit and miss and seems to be getting overridden by something downstream even though I can not find any plugins that should have this capability.

    Ideally, I want FTP over SSL to work rather than having to disable it.

  • The topic ‘Updating via SSL FTP fails after adding SSL certificate to sites’ is closed to new replies.