Author: dmzx
Special thanks to: martin
Extension Description:
This extension will add an easy download system to your forum, where you can offer your user to download files from your webspace.
- Added a bot-check (phpBB's own captcha) for guests downloading a file, shown on the exact same download URL - no separate confirm route or token needed. - Logged-in members are completely unaffected regardless of which link (internal or external) they use.
- This lets the "Can download files" guest permission stay enabled (needed for external links to keep working) while still filtering out automated/bot traffic from the per-user download log and file server.
- Requires the guest permission "Can download files in Download System" to be set to Yes - the captcha is now the gate for guests, not the permission itself.
Added template events to index_body.html, showcat_body.html and upload_body.html so other extensions can inject content (e.g. reviews, badges, achievement indicators) without modifying this extension's templates directly.
Consolidated all inline CSS from index_body.html and showcat_body.html into a single stylesheet, styles/prosilver/theme/downloadsystem.css, loaded via INCLUDECSS.
No functional or visual changes - purely template structure and asset organization.
- Added a public API facade (dmzx.downloadsystem.api): has_user_downloaded(), get_download_count(), get_user_download_count(), get_user_downloads() for other extensions to query without touching this extension's tables directly.
- Added a new per-user download history table (dm_eds_log) that records every download.
- Added dispatcher events dmzx.downloadsystem.download_completed_after and dmzx.downloadsystem.upload_completed_after for other extensions to hook into.
- Major refactor: split the ~1500-line monolithic admin_controller.php into 12 focused classes under controller/admin/, each handling a single ACP action, plus a shared trait for common logging/URL helpers. acp/downloadsystem_module.php now dispatches to the matching service per mode/action instead of one shared controller.
- Fixed a latent bug in the category-folder delete flow where a subdirectory cleanup call was missing its class reference (would have fatally errored had it ever been reached).
- Fixed a broken "selected" check on the category dropdown when adding a new download (comparison against the wrong value meant nothing was ever pre-selected).
- No functional/behavioural changes for board admins or end users beyond the two bug fixes above - this is an internal code-organization release.
- Added optional Ultimate Points Extension integration: users can be charged points to download a file.
- New ACP setting to enable/disable charging, only visible when Ultimate Points Extension is installed, off by default.
- New cost-per-download field on the add/copy/edit download forms, only visible when Ultimate Points Extension is installed.
- Front-end category page shows the user's points balance and a cost badge on downloads that have a price, only when both the extension is installed and charging is enabled.
- Balance is checked before streaming a file and points are deducted only after the file was confirmed readable, so a failed download is never charged.
- Behaviour is completely unchanged when Ultimate Points Extension is not installed, or when installed but the setting is left off.
- Added CSRF protection (add_form_key/check_form_key) to all ACP write actions: add/copy/edit/update download, create/edit category, save configuration.
- Added CSRF protection to the front-end upload form.
- Added link-hash protection (generate_link_hash/check_link_hash) to the category move up/down actions, since those are plain GET links rather than forms.
- Added explicit methods constraint to routing.yml (GET for display/serve routes, GET+POST for the upload route).
- Fixed the viewonline listener's outdated hardcoded 'app.php' front-controller assumption (generic prefix-strip, matching the fix already applied to 5 other dt2bapps extensions).
- Moved uploaded download files out of ext/dmzx/downloadsystem/files/ into store/dmzx_downloadsystem/files/ (board-root-relative), so extension updates/reinstalls can no longer overwrite user-uploaded files.
- New dmzx.downloadsystem.files_path parameter replaces 10+ scattered hardcoded path references.
- Added .htaccess to the new storage location to block direct access.
- Redesigned category and download listing pages: card-based layout, badges, "Read more" for long descriptions, real server-side search across all categories.
- Code update for phpBB 4.0.0-a1
- Added $language
- Add search in ACP.
- Changed table to div in ACP.
- Changed table to div on download page.
- Code update.
- Short syntax code.
- Fix code.
- Code update.
- Fixed errors on upload page and ACP.
- Code update.
- Code update in acp controller and composer.
- Added file extension to fa download icon.
- Added download count in ACP.
- Code update tables.yml
- Fixed downloading multiple files in one folder.
- Code added sweetalert2
- Fixed category move up and down.
- Added link for donation in ACP settings.
Code update for ACP pages
Code update.
ACP redo category section.
Code update.
Can upload category and file images.
Drop support of 3.1.x
Twig Update
Added number of files in subcategories.
Added subcategories to pagination.
Added Sub categories
Added images on download page. (indicate also sub categories)
Added correct pagination
Added Show on index upload for categories. (Admins can always see all categories)
Code update
Added Upload section, default on for admins.
Added new permission for upload section use.
Code update
Added log entries
Code update
Compatible with 3.2
Code update
Code update
Added permissions for latest phpBB
Screenshots:








Extension Download:
…
Installation:
- Download the latest release.
- Unzip the downloaded release, and change the name of the folder to `downloadsystem`.
- In the `ext` directory of your phpBB board, create a new directory named `dmzx` (if it does not already exist).
- Copy the `downloadsystem` folder to `/ext/dmzx/` if done correctly, you'll have the main extension class at
(your forum root)/ext/dmzx/downloadsystem/composer.json - Navigate in the ACP to `Customise -> Manage extensions`
- Look for `Download System` under the Disabled Extensions list, and click its `Enable` link.






