A WordPress plugin for tracking downloadables and inserting download cards in posts.
Requires: WordPress 5.8+, PHP 7.4+
Features
Custom post type for downloads: file URL, version, description, info link, icon, changelog
Editable HTML template with Mustache-style conditionals ({{#var}}...{{/var}})
Custom CSS with live-updating preview
Upload buttons for file and icon on the download edit screen (files go to uploads/downloads/)
Insert tools for classic editor (TinyMCE button) and block editor (Download block)
WP-CLI import from CSV: wp btdl import_downloads --file=/path/to/downloads.csv
Installation
Upload the bt-downloads folder to /wp-content/plugins/.
Activate the plugin via Plugins in WordPress.
Use Downloads in the admin to add downloads and Card template to customize HTML and CSS.
Admin
The plugin adds a Downloads item to the WordPress admin menu with sub-items: Downloads, Add New Download, and Card template.
Downloads menu in the WordPress admin sidebar
The main Downloads screen lists all download entries with title, shortcode ID, version, and date. Use the shortcode ID in [download ID] to embed a card.
Downloads list in the WordPress admin
When editing a download, you set the file URL, version, description, info URL, icon, dates, and changelog. The Shortcode meta box shows the exact shortcode (e.g. [download 128]) to use in posts or pages.
Edit Download screen with file, version, description, and shortcode
Card template
Under Downloads -> Card template you can edit the HTML template and custom CSS for download cards. The template uses variables such as {{title_str}}, {{file}}, {{version}}, {{description}}, and conditionals like {{#description}}...{{/description}}. A live preview updates as you type.
Download card template and custom CSS with live preview
Inserting downloads in the editor
Classic editor
A TinyMCE button opens a Select a download… dropdown. Pick a download to insert its shortcode.
Classic editor: Select a download dropdown
Block editor
Add a Download block. In the block settings sidebar, use the Download dropdown to choose which download to display.
Block editor: Download block with sidebar selector
After selecting a download, the block shows the card (e.g. title, download link, description) in the editor.
Block editor: Download block showing a rendered card
You can also use the block toolbar to pick a download when the block is selected.
Block editor: Download block toolbar with Download option
On the frontend, the shortcode (or block) renders a download card: title, download link, description, dates, and optional donate/info links, styled by your template and custom CSS.
Example download card on the frontend
Shortcode
Use [download 27] where 27 is the shortcode ID of the download (shown in the Downloads list and on the edit screen).
Created and Updated dates use datetime-local inputs (date and time) instead of text; stored as YYYY-MM-DD HH:mm.
Card preview meta box on download edit screen with iframe and “Preview with site theme” link.
AJAX card preview for template/CSS settings so both template and custom CSS update the preview.
“Set to current date/time” link for Created and Updated date fields in the download editor.
Template sanitization preserves {{variable}} and style=”{{…}}” placeholders; only strips script tags and event handlers.
Default download card template and CSS: icon wrap is a link, new layout and typography, default download icon SVG overlay, .dl-meta for published/updated.
1.0.1
2026-02-02 08:15
CHANGED
Created and Updated dates use datetime-local inputs (date and time) instead of text; stored as YYYY-MM-DD HH:mm.
Card preview meta box on download edit screen with iframe and “Preview with site theme” link.
AJAX card preview for template/CSS settings so both template and custom CSS update the preview.
“Set to current date/time” link for Created and Updated date fields in the download editor.
Template sanitization preserves {{variable}} and style=”{{…}}” placeholders; only strips script tags and event handlers.
Default download card template and CSS: icon wrap is a link, new layout and typography, default download icon SVG overlay, .dl-meta for published/updated.
1.0.0
2026-02-01 08:00
New: Adds a custom Downloads post type with fields for file URL, version, description, info link, icon, and changelog.
New: Download card system with editable HTML template (Mustache-style {{variable}} and {{#variable}}...{{/variable}} conditionals).
New: Custom CSS editor with live preview for download cards.
New: Classic editor integration via TinyMCE button and download picker.
New: Block editor integration via a Download block that renders the configured card.
New: WP-CLI import command wp btdl import_downloads --file=/path/to/downloads.csv for bulk-creating downloads from CSV.