Table of Contents
- Requirement: The Files Need to be Stored on Your Server
- What are the Reasons for Using the Force Download Option?
- Enabling the Force Download Option for the WP Express Checkout Plugin
- Download Manager Settings Configuration for Force Download
- Using a Non-Web Accessible Local File Path
Requirement: The Files Need to be Stored on Your Server
For the force download feature to function, it’s essential that the files are hosted on your server. This requirement stems from the fact that PHP streaming, which enables forced downloads, is not applicable to files stored on external websites. Thus, files not hosted on your server will not support the force download option.
What are the Reasons for Using the Force Download Option?
To ensure a file directly saves to a customer’s computer and the true location/URL of the file remains hidden, consider enabling the force download feature. Browser reactions vary; some may automatically download the file, while others prompt the user to save it.
Here are some reasons why you might want to use the force download option:
- Security: Using the force download option streams the file directly to the browser without revealing the file’s URL, concealing its true location and enhancing the security of your digital asset. This method is particularly advantageous for selling digital downloads.
- Large Files: Forcing a download of large files, like videos or software, allows users to download in the background and continue browsing your site without waiting for the file to load in the browser, enhancing user experience.
- Compatibility: Forcing a download bypasses issues with certain file types that may not display or function properly in various browsers or devices, ensuring users can access and use the files on their preferred platform.
When operating a website with paid downloads, it’s advisable to use the force file download feature. This ensures customers promptly receive their purchases while keeping the file’s true location/URL private.
Enabling the Force Download Option for the WP Express Checkout Plugin
The WP Express Checkout plugin allows you to choose specific digital products for enabling the force download feature. Below are the steps to enable this feature:
Step 1) Edit the product that you wish to enable the force download option for.
Step 2) After opening the product, scroll down to the Download URL option and check/tick the Enable Force Download checkbox.
Step 3) Save the product.
Download Manager Settings Configuration for Force Download
The force download option in the WP Express Checkout plugin generally works well with most site/server configurations. However, it depends on factors like PHP RAM and server settings, which might require adjustments for optimal performance on some sites. If issues arise, explore alternative download methods in the plugin’s ‘Advanced Settings’ menu, under the ‘Download Manager Settings’ section, to find a more compatible setup for your server.
The Download Manager Settings option is located in the ‘Advanced Settings‘ menu of the plugin. Go to the Advanced Settings menu then scroll to the section that looks like the following example:
Using a Non-Web Accessible Local File Path
For enhanced download security, you can use a non-web accessible local file path instead of a URL. This allows you to store sensitive downloads in a folder outside your “public_html” directory, preventing direct web access. Only customers who purchase the product can download it using the secure link provided.
Using a non-web accessible file path protects your digital products from unauthorized access and URL sharing, ensuring that your files are only accessible to customers. By placing your files outside publicly accessible directories, you add a robust layer of security against web crawlers and malicious actors.
To locate your home directory path, check cPanel (as shown in the example screenshot) or contact your hosting provider for assistance.
Note: Ensure that the file path you set is accurate; otherwise, the download will fail.