Skip to content

Digital download failed or zip file cannot be opened

You may find that downloading individual images works fine but downloading of an entire gallery fails — sometimes with a zip file that cannot be opened. The Digital Downloads add-on builds zip files of all the images in the gallery on the fly to save server space on your web hosting and also build a zip file of only the files the specific user needs. However, this process can be server intensive and cause the process to fail if the server cannot handle the load. This will all depend on the resources of your web server, the size, and quantity of images being put into the zip file. Also, if you are on a shared server, the available resources may fluctuate throughout the day based on how busy the other sites on your same server are.

Background Download Processing

As of Digital Downloads 3.2, large downloads can optionally be processed in the background instead of streaming immediately. You set a file count threshold — for example, 5 — and any download with more files than that is automatically queued for background processing. The customer sees an instant confirmation that their download is being prepared, and when the zip file is ready, they receive an email with a secure download link valid for 48 hours.

This is especially helpful on shared hosting or servers with limited resources, since the download no longer needs to complete in a single request. To enable this, go to Sunshine > Settings > Downloads and set the "Background download threshold" to the minimum number of files that should trigger background processing (minimum of 2). By default this is not enabled, and downloads stream immediately as they always have.

Increasing Memory

If you prefer immediate downloads or are still running into issues, try increasing the available memory for your WordPress installation. This solves the issue for most cases.

Still need help?

If you have not yet found your answer in the documentation articles, please contact support

Sunshine Photo Cart for WordPress