Changeset 3408713
- Timestamp:
- 12/03/2025 03:41:28 AM (4 months ago)
- Location:
- tnc-toolbox
- Files:
-
- 18 added
- 3 edited
-
tags/2.0.8 (added)
-
tags/2.0.8/assets (added)
-
tags/2.0.8/assets/index.php (added)
-
tags/2.0.8/assets/styles-config.css (added)
-
tags/2.0.8/assets/tnc-icon-light.png (added)
-
tags/2.0.8/core (added)
-
tags/2.0.8/core/core.php (added)
-
tags/2.0.8/core/index.php (added)
-
tags/2.0.8/core/settings.php (added)
-
tags/2.0.8/index.php (added)
-
tags/2.0.8/license.txt (added)
-
tags/2.0.8/locale (added)
-
tags/2.0.8/locale/index.php (added)
-
tags/2.0.8/readme.txt (added)
-
tags/2.0.8/tnc-toolbox.php (added)
-
tags/2.0.8/vendor (added)
-
tags/2.0.8/vendor/cpanel-uapi.php (added)
-
tags/2.0.8/vendor/index.php (added)
-
trunk/core/core.php (modified) (3 diffs)
-
trunk/readme.txt (modified) (3 diffs)
-
trunk/tnc-toolbox.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tnc-toolbox/trunk/core/core.php
r3397813 r3408713 62 62 add_action('admin_post_nginx_cache_purge', array($this, 'nginx_cache_purge')); 63 63 add_action('post_updated', array($this, 'purge_cache_on_update'), 10, 3); 64 add_action('transition_post_status', array($this, 'purge_cache_on_transition'), 10, 3); 64 65 add_action('_core_updated_successfully', function() { TNC_cPanel_UAPI::make_api_request('NginxCaching/clear_cache', [], true); }); 65 66 … … 262 263 263 264 /** 264 * Automatic cache purging 265 * Automatic cache purging on post update 265 266 */ 266 267 public function purge_cache_on_update($post_id, $post_after, $post_before) { … … 268 269 ($post_before->post_status === 'publish' && $post_after->post_status !== 'trash')) { 269 270 // Use the UAPI directly rather than function, to support automated (#31) 271 TNC_cPanel_UAPI::make_api_request('NginxCaching/clear_cache', [], true); 272 } 273 } 274 275 /** 276 * Automatic cache purging on post status transition 277 */ 278 public function purge_cache_on_transition($new_status, $old_status, $post) { 279 if ( 'publish' === $new_status && 'publish' !== $old_status ) { 280 // This hook also fires on-update, so we verify status change has occurred 270 281 TNC_cPanel_UAPI::make_api_request('NginxCaching/clear_cache', [], true); 271 282 } -
tnc-toolbox/trunk/readme.txt
r3398444 r3408713 5 5 Contributors: 6 6 Tags: NGINX, Cache Purge, Web Performance, Automatic Purge, Freeware 7 Tested up to: 6. 88 Stable tag: 2.0. 77 Tested up to: 6.9 8 Stable tag: 2.0.8 9 9 License: GPLv3 10 10 License URI: https://www.gnu.org/licenses/gpl-3.0.html 11 11 12 Made to help you fly online! Adds functionality (cache purge, etc) to WP - designed for NGINX-powered Servers on cPanel+WHM. 12 Designed for ea-NGINX (Cache/Proxy) on cPanel+WHM. Made to help you fly online! 🚀 13 13 14 14 … … 34 34 - Shows you the status of cP UAPI via disk usage info 35 35 - Purge when any ACF config options are saved 36 - Supports scheduled post publishing! 36 37 37 38 **Eager for even more capabilities?** … … 136 137 == Changelog == 137 138 139 = 2.0.8: Dec 3, 2025 = 140 * Scheduled Posts: Support scheduled post go-lives (#34) 141 * WordPress 6.9: Bump tested-to version from major v6.8 142 138 143 = 2.0.7: Nov 18, 2025 = 139 144 * Global Script: Update tool now purges artifact configs. -
tnc-toolbox/trunk/tnc-toolbox.php
r3398444 r3408713 6 6 * @author The Network Crew Pty Ltd (Merlot Digital) 7 7 * @license gplv3 8 * @version 2.0. 78 * @version 2.0.8 9 9 * 10 10 * @wordpress-plugin 11 11 * Plugin Name: TNC Toolbox: Web Performance 12 12 * Plugin URI: https://merlot.digital 13 * Description: Designed for NGINX-powered Serverson cPanel+WHM. Made to help you fly online!14 * Version: 2.0. 713 * Description: Designed for ea-NGINX (Cache/Proxy) on cPanel+WHM. Made to help you fly online! 14 * Version: 2.0.8 15 15 * Author: The Network Crew Pty Ltd (Merlot Digital) 16 16 * Author URI: https://tnc.works … … 30 30 31 31 // Plugin version 32 define('TNCTOOLBOX_VERSION', '2.0. 7');32 define('TNCTOOLBOX_VERSION', '2.0.8'); 33 33 34 34 // Plugin Root File
Note: See TracChangeset
for help on using the changeset viewer.