Transient Cleaner
Clean expired transients from your options table. The original and best! Transient housekeeping was added to the core of WordPress after version 5.8. However, I have decided to open up this plugin to all versions to allow for manual transient cleaning. Longer term I am working on a new version of the plugin, designed specifically for all WordPress releases. Tested up to PHP 8.2 Fully complies with WordPress coding standards Compliant with the stronger WordPress VIP coding standards, as well as compatibility with their platform Community plugin – visit the [Github page](https://github.com/dartiss/[repo link] “Github”) to get involved with the latest code development, request enhancements and report issues “Transients are a simple and standardized way of storing cached data in the WordPress database temporarily by giving it a custom name and a timeframe after which it will expire and be deleted.” Unfortunately, expired transients only get deleted when you attempt to access them. If you don’t access the transient then, even though it’s expired, WordPress will not remove it. This is a known “issue” but due to reasons, which are explained in the FAQ, this has not been adequately resolved. Why is this a problem? Transients are often used by plugins to “cache” data (my own plugins included). Because of this it means that expired data can be left and build up, resulting in a bloated database table. Meantime, this plugin is the hero that you’ve been waiting for. Simply activate the plugin, sit back and enjoy a much cleaner, smaller options table. It also adds the additional recommendation that after a database upgrade all transients will be cleared down. The Settings Screen Within Administration -> Tools -> Transients an options screen exists allowing you to tweak when you’d like cleaning to happen, including the ability to perform an ad-hoc run, and when you’d like the to be automatically scheduled. You can even request an optimization of the options table to give your system a real “pep”! Running in Lite mode A “lite” mode is available. By activating this the options screen will no longer appear and default settings will be used. The advantage? Improved performance to Admin and, especially if you’re running multi-site, no chance of anybody “tinkering” with the settings. To activate, use the following… define( 'TC_LITE', true ); This should be added to your wp-config.php file. Using hooks If you’re the type of odd person who likes to code for WordPress (really?) then I’ve added a couple of hooks so you can call our rather neat cleaning functions… housekeep_transients – this will clear down any expired transients clear_all_transients – this will remove any and all transients, expired or otherwise Acknowledgements I’d like to thank WordPress Developer Andrew Nacin for his early discussion on this. Also, I’d like to acknowledge the useful article at Everybody Staze for ensuring the proposed solution made sense, and W-Shadow.com for the cleaning code. Iconography is courtesy of the very talented Janki Rathod.
Top keywords
- transients10×1.97%
- wordpress8×1.57%
- expired6×1.18%
- options5×0.98%
- cleaning4×0.79%
- table4×0.79%
- added3×0.59%
- code3×0.59%
- data3×0.59%
- database3×0.59%
- expired transients3×0.59%
- github3×0.59%
Media Hygiene
The Media Hygiene plugin removes unused media from the WordPress library to free up space, reduce clutter, and improve server performance. With features like bulk delete and deep folder scanning, it’s a must-have for finding and deleting unused images and media. Introducing Media Hygiene Introducing the Media Hygiene plugin – the ideal solution for optimizing your WordPress media library! With this powerful plugin, you can quickly and easily remove all unused images, reducing clutter, and freeing up valuable server space. This plugin is a must-have for anyone looking to delete unused images in WordPress or remove unused images from the media library. Media Hygiene is fully compatible with major WordPress builders, including plugins like WooCommerce, custom fields and posts plugin, sliders, SEO, and more – making it versatile and convenient for all types of WordPress users. Unique features like “One shot delete” and “One-shot download” allow you to bulk delete media and download all images from the WordPress media library make it easy to keep your media library organized and up-to-date. Making offsite backups? Reduce the time and cost of disk space with a smaller backup file size. Say goodbye to a cluttered and disorganized WordPress media library, and hello to a cleaner, more efficient WordPress site! Whether you’re an agency, blogger, photographer, or business owner, Media Hygiene is the perfect tool for keeping your media library in tip-top shape. Get it now and keep your WordPress site super clean! Some use cases for website owners Unable to keep track of unused media files in the media library. Uploading the same images in different sizes to figure out optimal size and forgetting which one was actually used. Switching out an image in a post with another and can’t find it media library file. Updating the logo with a new version and don’t want the old one to be indexed by Google. Images included with purchased theme but never deleted after site was launched. After a website was redesigned or rebranded, there may a number of old images or media files no longer in use. Before migrating to a new hosting provider, cleaning up the media library may make it a smoother and faster migration process. Getting a warning from your hosting provider that you are hitting the storage limit, make your backups smaller. You have guest posts or contributors who may have left behind a number of images. Changing your product listings or discontinuing products in e-commerce sites may mean images are left unused. After trying out a theme, deactivation of theme may leave behind media files. How is it Different? Media Hygiene Pro scans the entire website using a number of different techniques. One way is to “visualize images/media in page source code” to confirm the existence of a media file even when builders/plugins/themes use specialized custom posts to display their widgets on-screen. File Types: Media Hygiene will recognize most if not all major file types stored in the WordPress media library. This includes but not limited to PDF, jpg, png, gif, mp4, mp3, csv, zip, rar, and txt files. We also cover alternative extension spelling such as jpeg. Standard Features: Dashboard – shows list of all unused media by occupied space and by type. Notifications – get email notifications when new files have been uploaded and not scanned on a specific schedule (daily, weekly, bi-weekly, monthly, quarterly) Site builder compatibility – works with all major site builders such as Elementor (see list below). Whitelist – keep files safe from deletion. Perfect for files linked to from off-site sources. Filtering – files by name and date. Backup – download unused media file individually or by page. Delete – remove files individually or by page. Scan – scanning process for all media files not linked to any page/post or other theme settings. Support – only through WordPress repository. Changelog Check latest here Compatibility Please check our website to see a completely list of compatible plugins/themes. Gutenberg – Standard Elementor Basic – Standard Bricks (builder) Divi (builder) WP Bakery Page Builder (builder) Beaver Builder (builder) Visual Composer (builder) Avada (theme) Enfold (theme) Flatsome (theme) More to come… Pro (available now) Customer Support – directly from the plugin – Pro Faster scanning through the use of WP-CLI (WordPress command line interface) Unique scanning process for multiple page builders with one click Advanced Filtering – Pro Media Filter by Year Media Filter by Type (jpg, png, gif, wmv, mp4, etc.) One Shot Download (all files) One Shot Removal (all files) Folder Scan (sub-folder scanning coming soon!) Woocommerce Custom Post Types SEO Plugins All in One Yoast SEO Press Custom Fields Plugins – Pro ACF Pods Custom Field Suite Custom Post Suits Sliders Meta Slider Slider Revolution Pro (coming soon) Custom Fields Plugins – Pro Jet Engine (coming soon) Meta Box (coming soon) CPT UI (coming soon) Remote server backup and restore – Pro (coming soon) Scheduled Scans – Pro (coming soon) Custom Email Notifications – Pro (coming soon) WPML / Weglot / TranslatePress (coming soon)