• Using WooCommerce 2.4.7 (latest update), when I go to attach a digital file (I’ve tried PDFs and ZIPs) to a product page, I get the following message:

    The downloadable file /wp-content/uploads/woocommerce_uploads/2015/09/[file-name].zip cannot be used as it does not exist on the server.

    First off, the file does exist on the server.

    The message goes away if I hard code the File URL to be the full path name. I added “https://shop.[my-domain-name].com/” at the beginning of the prepared URL that the system automatically generated when using the media manager window. So if I hard code the URL of the desired product, no error messages occur causing me to think everything is OK.

    When I generate a customer order, and click on the download link provided to the customer, I get a 403 Forbidden message in my browser window, but even worse, the relative URL for the attempted file download is displayed on the page like so:

    Forbidden

    You don’t have permission to access /wp-content/uploads/woocommerce_uploads/2015/09/[file-name].zip on this server.
    Apache/2.4 Server at shop.trainingdoulas.com Port 80

    The full URL is displayed in the browser’s address bar as well, instead of the customer link generated by WooCommerce.

    Also for reference sake, I have the File Download Method set to Force Download, because the other options didn’t work in my environment for reasons I don’t immediately recall(as this setting was set several months ago).

    The final bit of info that I can provide is that files that were uploaded before last month seem to be behaving just fine. However, I went and attempted to update another one of my older products, thinking that this change needed to be made to all my file (making the digital product URL absolute), and it now is broken too. I can’t go back to the way it was.

    I’ve searched for an answer on Google with no success. I’ve also found these two other posts that seemed related but without success. I went and located the file suggested in the second link but it had already been updated to the suggested change found here.

    Thanks for your attention.

    https://www.ads-software.com/plugins/woocommerce/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter Brent Leavitt

    (@brentleavitt)

    I’m still interested in seeing if anyone else has experienced this behavior. Judging by the lack of response, this seems to be a unique issue to my particular installation. It is possible that it has something to do with my SSL configuration or some other unique combination of environmental variables. I know that my host recently updated to PHP 5.6, but I don’t think that should be a cause for concern either.

    All that said though, the only suitable fix that I have found so far is to link the files with the fully qualified URL that doesn’t get rejected by the WooCommerce check point. Then after the fact, I log in to the database and revert the links back to the relative URLs, so that they are actually linking correctly when the products are being purchased. That seems to have fixed the issue. Because I’m modifying JSON strings in the database, I’m also having to update character counts in the JSON strings as well. Clearly, not the ideal solution to the problem, but since I don’t work in large volumes of products, it’s not a big deal to update one product at a time.

    Hi, let me know, if you find solution for this problem. Thanks ??

    Brent, i’m suddenly having the same issue. I’m about to try your workaround, but I would love to know if you have found any additional information on this.

    I am using SSL as well, but my staging site doesn’t yet it as the same problem so i don’t think they’re related, but …

    Thanks –

    Hi Brent and any others .. I also have this problem on some downloadable files but not others. I cannot see any difference apart from the one that works being published in Feb 15 and the one that does not in March 15. The one tht does not used to work but I cannot trace an event that stopped it.

    Any updates from any of you much appreciated, Tim

    Caleb Burks

    (@icaleb)

    Automattic Happiness Engineer

    Could you post your system status reports here? Could help narrow down the cause: https://www.ads-software.com/support/topic/before-posting-gather-the-following-details

    I’d first check the file permissions. Sounds like something could be wacky there.

    Also, make sure there isn’t another plugin/theme causing the issue: https://www.ads-software.com/support/topic/how-to-debug-issues-after-updates.

    Erich

    (@erichboileau)

    You wouldn’t happen to be using Root Relative URLs plugin (or something similar), would you? It comes default with a few automated WordPress installers (Rackspace’s to name one), and causes all types of nightmares. Even disabling this plugin doesn’t help because it installs extra lines of code in config.php.

    https://www.ads-software.com/plugins/root-relative-urls/

    I had the same problem you described, and clearing out that plugin and the vestiges of it from config.php solved the problem for me.

    Don’t know if this will help, but worth a check!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘The Downloadable File Doesn't Exist on Server/ Forbidden Access on File Download’ is closed to new replies.