Descrizione
WP Attachments turns the files you upload to a post into a clean, automatic download list. Attach a file while editing, and it shows up under your content — no manual links, no shortcodes to remember.
It also fills the gaps in the WordPress Media Library, letting you attach, unattach and reattach files without leaving the screen you are on.
Key features
- 🤖 Lists attachments automatically after the post content
- ℹ️ Metabox for managing, previewing, renaming and reordering the files of a post
- 🔃 Attach, Unattach and Reattach actions in the Media Library
- 🔢 A Files column in the post and page lists: see the count, click through to the files
- 🔢 Download counter that ignores crawlers, prefetches and repeat clicks
- ♿ Reordering works with the mouse, the keyboard and screen readers
- 🧑💻 Filters for developers who want to change the markup
- 🛍️ WooCommerce compatible, including High-Performance Order Storage
- 🎨 Four icon packs for the frontend list
- 📜 Works with posts, pages and custom post types
- 🎢 Templates you can customise: title, date, size, caption, downloads and more
Contributi
- Part of WPGov.it, providing open source solutions for Italian Public Government websites.
- Grazie alla community italiana di Porte Aperte sul Web per le prove e le idee.
- Metabox basato su IJ Post Attachments
- Alcune icone da Yusuke Kamiyamane.
Screenshot





Installazione
- Install via the WordPress.org plugin directory or upload the files to your server.
- Activate the plugin. To customise it, go to Settings WP Attachments.
- While editing a post, page or custom post type you will find the Media Attachments metabox. Extra actions are available in the Media Library: Attach, Unattach and Reattach.
FAQ
-
How do I hide the attachment list on a specific post or page?
-
Open the Media Attachments metabox while editing and switch off Display attachments in frontend, at the bottom left. The files stay attached, they are simply not listed on the site.
You can also set the default for a whole post type under Settings WP Attachments Post Type Permissions.
-
How do I avoid the same file being listed twice?
-
Do not insert the link manually. A file uploaded from the editor is attached to the content automatically and listed by WP Attachments, so you can simply close the media popup after uploading.
-
How do I reorder the files?
-
Three ways, all of which save straight away:
- drag a row by the grip on its left;
- use the Move up / Move down buttons on each row;
- focus the grip and press the up or down arrow key.
-
How do I see which files belong to a post?
-
The Files column in the post and page lists shows how many files each one has. Click the number to open the Media Library filtered to just those files.
-
Can I change the date format of the list?
-
Yes, under Settings WP Attachments Date Format. It accepts the standard PHP date characters and applies to the
%DATE%tag. Leave it empty to follow Settings General Date Format. -
Does the download counter count everything?
-
No. It skips browser prefetch requests and known crawlers, and it ignores repeat hits from the same visitor on the same file for a few minutes. Those requests still receive the file, they just do not move the number.
-
Which files can be previewed in the metabox?
-
Images, video, audio, PDF and plain text open in a preview dialog. Any other format shows its icon and a download link.
-
Filtri per sviluppatori
-
- wpatt_list_html — the whole list markup (
$html) - wpatt_before_entry_html — a single entry, before the tags are replaced (
$html) - wpatt_after_entry_html — a single entry, after the tags are replaced (
$html) - wpatt_accepted_formats — return a falsy value to hide a file (
$mime) - wpatt_download_throttle — how long the same visitor is ignored for the same file (
$seconds,$attachment_id) - wpatt_count_download_request — whether the current request may increment a counter (
$countable)
Examples
function my_custom_function( $html ) { // Alter the final HTML return $new_html; } add_filter( 'wpatt_list_html', 'my_custom_function' ); function my_pdf_only( $mime ) { // Only show PDFs in the list return $mime === 'application/pdf'; } add_filter( 'wpatt_accepted_formats', 'my_pdf_only' ); // Count each visitor at most once per hour add_filter( 'wpatt_download_throttle', function () { return HOUR_IN_SECONDS; } );There is also
wpatt_get_attachments_html( $parent_id ), which returns the list for any parent ID without going through thethe_contentfilter. - wpatt_list_html — the whole list markup (
Recensioni
Contributi e sviluppo
“WP Attachments” è un software open source. Le persone che hanno contribuito allo sviluppo di questo plugin sono indicate di seguito.
Collaboratori“WP Attachments” è stato tradotto in 6 lingue. Grazie a chi traduce per il contributo.
Traduci “WP Attachments” nella tua lingua.
Ti interessa lo sviluppo?
Esplora il codice segui il repository SVN, segui il log delle modifiche tramite RSS.
Changelog
6.0.3 2026-08-31
- New: a Files column in the post, page and custom post type lists shows how many files are attached to each one, and links straight to them in the Media Library.
- New: the Edit action in the metabox now opens media modal in place, so titles, captions and alt text can be changed without leaving the editor.
- Security: fixed a cross-site request forgery issue.
- Accessibility: files can now be reordered with the keyboard, and the frontend sort control works without JavaScript.
- The download counter now ignores crawlers and browser prefetch requests.
- Fixed wrong file sizes, the Date Format setting that had no effect, and the first attachment not showing up until the page was reloaded.
- New file type icons, and admin assets now load only on the screens that use them.
- WooCommerce: declared compatibility with High-Performance Order Storage.
5.3.4 2026-03-14
- Minor fixes and improvements.
5.3 2026-02-02
- Better permission handling
- Redesigned settings screen
5.2.1 2026-01-19
- Minor fixes and improvements.
5.2 2025-06-09
- Fixed regression with images (thanks @reesher + @steeltape for feedback)
- Added option to enable/disable for specific custom post types (completely or only frontend)
- Other minor fixes and improvements.
5.1 2025-05-25
- Date placeholders in attachment templates now use the WordPress date format setting (
Settings > General > Date Format) for better localization and consistency. - Improved templating: You can now use WordPress date formatting in your custom templates, and templating settings are more flexible and reliable.
- Other minor fixes and improvements.
- Major code refactoring for improved stability and maintainability
- Significant performance improvements
- Enhanced security throughout the plugin
- Improved admin capabilities and permission handling
- Brand new metabox for easier attachment management
- Refreshed admin columns for better overview and usability
5.0.12
- Latest stable release
5.0.6 2023-02-15
- Controllo di compatibilità
- Security fixes
- Minor changes
5.0.4 2021-10-20
- Controllo di compatibilità
- Linked development workflows on GitHub
- Minor changes
5.0 2020-11-28
- WooCommerce compatibility: add files to client orders
- Major improvements and technical changes
- Rewritten add_media popup with custom behavior
- Removed old translation files, now using translate.wordpress.org
- Minor changes
4.4.2 2020-04-29
- Miglioramenti minori
4.4.1 2020-02-20
- Controllo di compatibilità
Version 4.4 18/11/2017
- Corretto bug critico per le icone mancanti in WP 4.9
- Potrebbero verificarsi dei problemi nelle precedenti versioni di WP per le icone. Aggiorna!
Version 4.3.6 10/01/2017
- Testato con WP 4.7
- Corretto un avviso php nei tipi di post personalizzati con capacità mappate
Version 4.3.4 06/07/2016
- Controllo di compatibilità con WP 4.6
Version 4.3.3 02/04/2016
- Corretto errore nella data del metabox
- Testato con WP 4.5
Version 4.3.2 19/02/2016
- Corretta segnalazione di errore PHP quando è attivo il debug
Version 4.3.1 18/02/2016
- Esclusione automatica del menu a discesa, se gli allegati < 2
Version 4.3 23/12/2015
- Aggiunta opzione per mostrare un menu a discesa per l’ordinamento
- Miglioramenti vari e correzioni di errori
- Aggiunto supporto per translate.wordpress.org
Version 4.2 02/08/2015
- Aggiunte funzioni e filtri per sviluppatori
- Miglioramenti minori
- ReadMe dei cambiamenti (aggiunte FAQS)
Version 4.1.2 6/07/2015
- Aggiunta traduzione es_ES da Joaquín Alejandro Duro Arribas
- Cambiamenti nel ReadMe
Version 4.1.1 1/06/2015
- Testato con l’ultima versione beta
- Cambiamenti nel Readme
Version 4.1 26/04/2015
- Aggiunta opzione per escludere gli utenti registrati dal contatore di download
- Corretto template “esteso”
- Correzioni minori
- Cambiamenti minori al readme.txt
Version 4.0.2
- Corretto difetto dell’errore 404 quando il titolo del file contiene caratteri speciali (solo per il contatore di download)
- Miglioramenti minori
Version 4.0.1
- Corretto l’errore di download 404 per alcuni permalinks quando il contatore è abilitato
Version 4.0
- Nuova e migliore metabox
- Aggiunta la funzione contatore di download
- Agiunti temi per le icone
- Aggiunti schemi multipli
- Opzioni ridisegnate
- Miglioramento delle prestazioni (2 volte più veloce)
- Miglioramenti minori
Version 3.7 05/03/2015
- Aggiunto filtro ed opzione per impostare il plugin alle viste singola e di pagina
- Miglioramenti minori delle prestazioni
- Corretta la versione errata nel pannello delle impostazioni
- Stile migliore per la lista degli allegati
Version 3.6.1 28/02/2015
- Agiunto controllo per i post protetti da password
Version 3.6 28/02/2015
- Prestazioni migliorate
- Metabox mgliorato (più veloce & più carino)
- Pannello opzioni migliorato
- Aggiunta opzone per disattivare il plugin in determinate pagine
Version 3.5.6 21/10/2014
- Corretto conflitto css con il tema WordPress delle scuole italiane “pasw2015”
Version 3.5.5 05/09/2014
- Aggiunta icona del plugin
- Aggiunta traduzione in serbo sr_RS
- Cambiamenti al readme.txt
Version 3.5.4 26/07/2014
- Corretto un possibile conflitto con altri plugins (es. Members)
- Corretta la traduzione mancante del bottone “Update” nel pannello delle opzioni (per tutte le lingue)
Version 3.5.3 20/07/2014
- Aggiunta taduzione in Portoghese Brasiliano da Henrique Avila Vianna
Version 3.5.2 15/07/2014
- Corretta la mancata presenza del bottone “Aggiungi media” quando non vi è alcun file allegato
- Corretta la mancanza del metabox nelle pagine aggiungi-nuova dell’ “admin”
- Aggiornato l’uploader per essere identico a quello integrato in WordPress
- Migliorato lo stile del bottone “Add media” per corrispondere esattamente allo standard di WordPress ‘
Version 3.5.1 12/07/2014
- Testato e funzionante con WordPress 4.0 (beta)
Version 3.5 09/07/2014
- Aggiunto collegamentodisallega nella pagina di amministrazione dei media
- Aggiunto collegamentodisallega nell’editor di pagina/post/cpt
- Migliorato il back-end del metabox
- Migliorata la capacilità di gestione per le funzioni allegare/riallegare/disallegare
- Migliorata la gestione di alcune variabili
- Aggiunta funzione per controllare se un file non esiste e si deve saltare il calcolo dello spazio (al fine di evitare errori di front-end)
Version 3.4 08/07/2014
- Aggiunto collegamentoriallega nella pagina di amministrazione dei media
- Aggiunto collegamentoallega per il file disallegato nella pagina di amministrazione dei media
Version 3.3 28/03/2014
- Aggiunta un’opzione per aprire i files in una nuova scheda [in Impostazioni -> WP Attachments]
- Corretto un conflitto con il plugin “Membri” che causava la comparsa del metabox nella sua pagina delle opzioni
- Aggiunto un/icona “occhio” nel metabox dell’editor per indicare che il file sarà elencato
Version 3.2.3 26/03/2014
- Risolto conflitto con alcuni plugin per newsletter aggiungendo codice per evitare la lista degli allegati se l’id del post scelto è nullo
Version 3.2.2 12/03/2014
- Aggiunto supporto per MP3, ODT, ODS
- Cambiata la dimensione del testo per i piccoli file: ora viene mostrato “< 1KB” invece di “n B”
- Migliore compatibilità con Internet Explorer
Version 3.2.1 03/03/2014
- Aggiunto wp_enqueue_style per caricare lo stile dal css
- Prestazioni migliorate
Version 3.2 03/03/2014
- Nuovo sistema di localizazione. Traduzioni in Inglese & Italiano già incluse
- Nuovo back-end per i metabox . Questo è in versione beta, ma io sono sicuro che vi piacerà!
- Pagina delle opzioni migliorata
Version 3.1.4 4/11/2013
- Corretta la mancanza di ‘Backend.php’ (questa funzione sarà disponibile nelle prossime versioni (3.2+)
Version 3.1.3 27/10/2013
- Altre correzioni
Version 3.1.2 27/10/2013
- Corretto un bug che in alcuni casi causava il mancato caricamento del contenuto
Version 3.1.1 19/10/2013
- Il titolo della lista ora viene nascosto correttamente
Version 3.1 15/09/2013
- Corretta la mancanza di icone per le immagini
- Aggiunta l’opzione per escludere le immagini dalla lista
- Migliorate le impostazioni del layout della pagina
Version 3.0.4 24/08/2013
- Readme cambiamenti minori
Version 3.0.3 23/08/2013
- Migliorato l’aspetto nel Css
Version 3.0.2 23/08/2013
- Corretto l’errore di attivazione: uscita inaspettata carattere – 1
Version 3.0.1 22/08/2013
- Corretta la mancata interpretazione di uno shortcode esterno
- Corretto il codice CSS ridondante
- Migliorato loop
- Il titolo dell’elenco non compare più per gli allegati vuoti
Version 3.0 22/08/2013
- Aggiunto Css per mostrare le icone
- Aggiunta dimensione file
- Aggiunti dati dell’allegato
- Aggiunto panello delle opzioni
Version 2.0 04/07/2013
- Prima versione funzionale. Buon divertimento!
Version 1.0 07/01/2012
- Prima Versione
