file_field_download
The File Field Download module provides a simple yet powerful solution for Drupal websites that need to offer multiple files as a single download.
It enables site administrators to create a download link that automatically compresses any files attached to a node into a single ZIP archive, streamlining the file download process for end users.
This module is perfect for content managers who need to distribute document collections, media packages, or any group of related files efficiently.
Features
- Creates a custom "Download Link" field type that can be added to any entity.
- Compresses multiple files from specified file fields into a single ZIP archive.
- Allows administrators to select which file fields should be included in the ZIP download.
- Customizable download link label to improve user experience.
- Supports customization of the downloaded ZIP filename.
- Works seamlessly with existing file fields in your content types.
- Integrates with Drupal's entity system, making it compatible with any entity that uses file fields.
- Minimizes server load by generating ZIP files on-demand.
Post-Installation
After installing the Download module, follow these steps to set it up:
- Navigate to the "Structure" section in your Drupal admin menu.
- Select "Content types" (or another entity type you wish to use).
- Choose the entity type you want to enhance with the download functionality.
- Click "Manage fields" and then "Add field".
- From the dropdown menu, select "Download Link" under the "Reference" section.
- Give your field a name (e.g., "Download Files") and save.
- In the field settings, you can:
- Set a custom label for the download link.
- Select which file fields should be included in the ZIP archive.
- Configure the format of the downloaded ZIP filename.
- Save your field settings.
No additional configuration pages are necessary. The module works directly with the fields you've configured on your content types.
Additional Requirements
This module requires:
- Drupal 10.x or higher.
- PclZip library (installed via Composer).
To install the required PclZip library, you can either:
- Configure Drupal composer to include the library.
- Use the Composer Manager extension.
Similar projects
-
Download
This module serves as the codebase for the File Field Download module. -
Zip Field Files
This module allows users to download all files associated with a content item in a single click. It provides a field formatter that adds a download link for easy access.
Difference: Unlike File Field Download, which allows users to select specific files, Zip Field Files downloads all files at once without the option for individual selection. -
Zip File Field
Allows uploading a ZIP file, which is automatically extracted upon entity save.
Difference: Unlike File Field Download, which generates ZIP files dynamically, Zip File Field works with pre-uploaded ZIP files and extracts them when saving the entity. -
Download All Files
Provides a field formatter for the 'file' field type called "Table of files with download all link," which groups files into a single download, zipping them together.
Difference: While similar to Zip Field Files, it specifically works with the "file" field type and organizes the files in a table with a download all link. -
File Compressor Field
This module provides a "File Compressor" field type that archives and compresses attached files into a ZIP file after the entity is saved, using a plugin-based architecture. -
Views Files Downloader
Enables downloading all files attached to a view or node, generating a ZIP file for site visitors.
Difference: File Field Download focuses on managing downloads per content instance, while Views Files Downloader allows downloads from views. -
Media Download All
This module provides a media entity reference field's display formatter that allows downloading all associated files in a single ZIP file.
Difference: This module is specifically designed for media entities, whereas File Field Download supports a broader range of content entities. -
File Download
Provides two formatters for direct downloads and tracks downloads via a submodule.
Difference: File Field Download allows users to bundle multiple files into a single ZIP, whereas File Download focuses on direct file downloads without compression. -
File Download Link
This module offers customizable download links for File and Image fields, with Token support.
Difference: Unlike File Field Download, File Download Link provides customizable download links but does not compress multiple files into a ZIP. -
DownloadFile
Generates direct download links for file and image fields, supporting accessible formatting, file type icons, and requiring no external dependencies.
Difference: Focuses on direct file downloads, whereas File Field Download bundles multiple files into a ZIP archive. -
Media Export Files
Allows users to download all media files from a Drupal site in a ZIP archive, useful for backup, sharing, or migration.
Difference: This module is specifically designed for exporting media files, while File Field Download supports various file types and allows more granular file selection.