A WordPress plugin that streamlines your cache clearing.
| Plugin | Primary Cache Type |
|---|---|
| WP OPcache | PHP OPcache |
| OPcache Manager | PHP OPcache |
| LiteSpeed Cache | Server-Side Page Cache |
| CLP Varnish Cache | Server-Side Page Cache |
| WP Super Cache | Page Cache |
| W3 Total Cache | Page Cache |
| Cache Enabler | Page Cache |
| WP Rocket | Page Cache |
| Redis Object Cache | Object Cache |
| CDN Enabler | CDN |
By default, the master toolbar is being shown to users with the Administrator role. It may make sense to lower this to include Editors but you have to make sure that your caching plugins also allow Editors to clear the cache. Here's a snippet to set the capability to Editor and above:
add_filter( 'ccc_add_toolbar', function ( $capability ) {
return 'edit_pages';
});By default, third party toolbars are hidden for everyone. You can set a high capability so they are still shown to some people, but this defeats the purpose of the plugin. Here's a snippet to set the capability to Administrator and above:
add_filter( 'ccc_keep_third_party_toolbars', function ( $capability ) {
return 'manage_options';
});add_filter( 'ccc_toolbar_position_right', '__return_true' );Found a bug? Anything you would like to ask, add or change? Please open an issue so we can talk about it.
Pull requests are welcome. Please try to match the current code formatting.
