WordPress allows the admin to move pages, posts, comments, and custom post types to the trash just like the Recycle Bin on Windows. For the media, WordPress can only permanently delete a file from the media library.
Media Trash Button is a WordPress that replaces the Delete Permanently link with a Trash link which allows you to move the selected media file to Trash instead of deleting it permanently.
How to use it:
1. Install and enable the Media Trash Button plugin on the website.
2. Add the following PHP snippets to your wp-config.php file.
define( 'MEDIA_TRASH', true ); /* That's all, stop editing! Happy publishing. */
3. Click the Trash button under the media entry to move the file to the Recycle Bin.
4. You can view all trashed files under the View Trash tab and click the Restore link to restore them when needed.
Download WordPress Plugin:
You can download this free WordPress plugin using the download button below. Unless otherwise stated, the WordPress plugin is available under GNU General Public License.
Author: Katsushi Kawamori
Don’t forget to share this WordPress plugin and also check out other awesome plugins on our site.