| @@ -1,11 +1,11 @@ | ||
| 1 | 1 | === WebberZone Top 10 — Popular Posts === |
| 2 | 2 | Tags: popular posts, post views, page views, most viewed posts, popular posts widget, trending posts, post views counter, multisite, block, shortcode |
| 3 | 3 | Contributors: webberzone, ajay |
| 4 | 4 | Donate link: https://wzn.io/donate-wz |
| 5 | -Stable tag: 4.4.1 | |
| 6 | -Requires at least: 6.6 | |
| 7 | -Tested up to: 7.0 | |
| 5 | +Stable tag: 4.5.1 | |
| 6 | +Requires at least: 6.8 | |
| 7 | +Tested up to: 7.1 | |
| 8 | 8 | Requires PHP: 7.4 |
| 9 | 9 | License: GPLv2 or later |
| 10 | 10 | |
| 11 | 11 | Track post views and page views, and display popular posts and trending content on your WordPress site. |
| @@ -42,8 +42,9 @@ | ||
| 42 | 42 | = Features in Top 10 Pro = |
| 43 | 43 | |
| 44 | 44 | * __Enhanced Tracking and Performance__ |
| 45 | 45 | * __Fast and High-Traffic Trackers__: Alternative tracking methods for improved performance on busy sites |
| 46 | + * __Site-wide Tracking__: Track views for the front page, posts page, archives, and searches in addition to individual content | |
| 46 | 47 | * __Query Optimisation__: MySQL `MAX_EXECUTION_TIME` directive to prevent long-running queries, configurable via settings and the `top_ten_query_max_execution_time` filter |
| 47 | 48 | * __Data Retention Override__: Customizable data retention period (default 180 days via `TOP_TEN_STORE_DATA`) |
| 48 | 49 | * __Lazy Loading__: Render popular posts lists via JavaScript only when they are about to scroll into view, so full-page caching plugins can serve a page without baking in a live popular-posts query. Works with content, shortcodes, widgets, and the Popular Posts block; disable per instance with the `lazy_load` shortcode/block attribute |
| 49 | 50 | |
| @@ -172,161 +173,59 @@ | ||
| 172 | 173 | [Report a security vulnerability.](https://patchstack.com/database/vdp/top-10) |
| 173 | 174 | |
| 174 | 175 | == Changelog == |
| 175 | 176 | |
| 176 | -= 4.4.1 = | |
| 177 | += 4.5.1 = | |
| 177 | 178 | |
| 178 | -*Release Date - 25 July 2026* | |
| 179 | +*Release Date - 19 September 2026* | |
| 179 | 180 | |
| 180 | 181 | * Fixed: |
| 181 | - * "Exclude Front page and Posts page" setting had no effect in the widget/block/shortcode output; the front and posts page IDs were compared as strings against integer post IDs during exclusion filtering. | |
| 182 | - * Settings page sidebar overlapped the tab content; the layout now uses flexbox instead of relying on float ordering. | |
| 182 | + * Security: Hardened thumbnail dimension handling to prevent stored Cross-Site Scripting by an Author-level user via block attributes. | |
| 183 | 183 | |
| 184 | -= 4.4.0 = | |
| 184 | += 4.5.0 = | |
| 185 | 185 | |
| 186 | -*Release Date - 22 July 2026* | |
| 186 | +Release date: 7 September 2026 | |
| 187 | +Release post: https://webberzone.com/announcements/top-10-v4-5/ | |
| 187 | 188 | |
| 188 | -* Features: | |
| 189 | - * New "Features" tab under Settings: turn off plugin features that you do not use and their code will not be loaded at all. You can toggle the Popular Posts and Post Count blocks, popular posts feeds, legacy widgets, Query block, Featured Image block, Popular Posts Pro block, Fast and High-traffic trackers, Pro dashboard widgets, and Popular Authors. | |
| 190 | - * New "Tracking method" setting under Settings » Counter/Tracker » Tracker settings: choose between Funnel tracking (default; views are buffered and merged into the count tables every few minutes) and Legacy tracking (views are written directly to the count tables on every visit, as in versions before 4.3). Switch to Legacy tracking if view counts are not updating on your site, e.g. when WP-Cron is disabled or unreliable. Note that Legacy tracking does not populate the visits log table. The Fast and High-traffic trackers respect this setting; regenerate the High-traffic config file after changing it. | |
| 191 | - * New "Number format style" setting under Settings » Counter/Tracker » Counter settings: choose Abbreviated to display large view counts in a compact form, e.g. 1.2k or 3.4M, wherever counts are displayed. The default remains the full locale-formatted number. It can be overridden per instance with the `number_format_style` shortcode/block attribute, and the suffixes and rounding can be customised via the `tptn_number_format_abbreviations` and `tptn_abbreviate_number_decimals` filters. | |
| 192 | - * WP-PostRatings integration: new "Show WP-PostRatings rating" setting under Settings » Posts list displays each post's rating next to it in the popular posts list, either as the star rating rendered using the WP-PostRatings plugin's own templates or as the average score number. Off by default and only takes effect when the free WP-PostRatings plugin is active. It can be overridden per instance with the `show_ratings` shortcode/block attribute (`stars` or `score`), and the markup can be customised via the `tptn_ratings` filter. | |
| 193 | - * [Pro] New "Lazy load popular posts" setting under Settings » General: load popular posts lists via JavaScript only when they are about to enter the viewport instead of rendering them inline, so full-page caching plugins can serve a page without embedding a live popular-posts query. Applies to content, shortcodes, widgets, and the Popular Posts block. Off by default. Override it per instance with the `lazy_load` shortcode/block attribute, e.g. `lazy_load="0"`. Not applied on feeds, admin, AJAX, cron, WP-CLI, or AMP pages. | |
| 189 | +**Added** | |
| 194 | 190 | |
| 195 | -* Improvements: | |
| 196 | - * The `[tptn_list]` shortcode now accepts all registered settings as attributes, including newly added settings that are not yet present in the saved settings. | |
| 197 | - * Redesigned settings page with vertical tab navigation, which is responsive and reverts to horizontal tabs on smaller screens. The settings page now opens on the Features tab. | |
| 198 | - * New search box above the settings tabs: type to instantly filter settings across all tabs. Matching settings are shown grouped by tab with the search term highlighted in their labels and descriptions, each tab displays a count of its matches, and clicking a tab scrolls to its results. You can also search by the internal setting key, e.g. `cache_time`. A single Save Changes bar replaces the per-tab buttons while searching, and the search is fully keyboard and screen reader accessible. | |
| 199 | - * Checkbox settings now display as toggle switches. | |
| 200 | - * Settings that have been changed from their default value are marked with an indicator dot, with a legend below the buttons. The default value is also displayed below each setting's description. | |
| 201 | - * Admin styles and scripts are now versioned with the plugin version so browsers reliably pick up changes after an update. | |
| 202 | - * Bot/crawler detection (used by the "Do not track bots" tracker setting) now uses the actively maintained Crawler-Detect library for broader, more accurate coverage, alongside the existing built-in pattern list. | |
| 191 | +* [Pro] Popular Posts elements for Elementor, Bricks Builder and WPBakery Page Builder. | |
| 192 | +* [Pro] Optional site-wide tracking for front pages, posts pages, archives and searches. | |
| 193 | +* [Pro] Reduce Daily Table Size tool to combine older hourly records. | |
| 194 | +* [Pro] `wp top10 db rollup` command for CLI and multisite use. | |
| 203 | 195 | |
| 204 | -* Fixed: | |
| 205 | - * Admin banner no longer causes a horizontal scrollbar on the plugin's admin pages. | |
| 206 | - * Custom period label ("Daily" vs "Custom (N days)") on the Dashboard widget, Popular Posts submenu, and post list Views column now matches the data actually shown, instead of always following the site-wide Custom period setting. | |
| 207 | - * Post list Views column, and its sort order, now counts today only instead of the full Custom period range. | |
| 208 | - * Left thumbnail style no longer stacks the thumbnail above the text in narrow containers such as sidebar widgets; it now stays side by side unless there genuinely isn't room. | |
| 209 | - * New "Fix Cron Schedules" tool under Top 10 » Tools to clear and reschedule the maintenance and aggregation cron jobs if they stop running. | |
| 210 | - * The Tools page and an admin notice now surface WP-Cron scheduling errors (e.g. "The cron event list could not be saved") directly in the dashboard instead of only appearing in the PHP error log. | |
| 211 | - * [Pro] Fast and High-traffic trackers now respect the "Do not track bots" setting; previously they recorded views for bots and other automated user agents regardless of this setting. | |
| 196 | +**Changed** | |
| 212 | 197 | |
| 213 | -= 4.3.2 = | |
| 198 | +* Reduced admin overhead on large multisite networks by caching table metadata, probing WPP tables directly and using estimated row counts on the Tools page. | |
| 199 | +* Sped up the dashboard with index-friendly `dp_date` ranges, optimized network popular-post queries and on-demand loading of historical tabs. | |
| 200 | +* Setting defaults are now resolved from a lightweight list instead of building every settings field, so reading an option early in the page load no longer loads translations too early. | |
| 214 | 201 | |
| 215 | -*Release Date - 8 July 2026* | |
| 202 | +**Security** | |
| 216 | 203 | |
| 217 | -* Improvements: | |
| 218 | - * Dynamic post counts now load more reliably and are faster in modern browsers. | |
| 219 | - * Enhanced time range labeling: Interface now dynamically shows "Daily" for 1-day periods or "Custom (N days)" for longer periods, making the UI more accurate based on actual settings. | |
| 204 | +* Hardened settings sanitization for users without the `unfiltered_html` capability. | |
| 205 | +* Hardened referer and array handling in settings sanitization, and renamed the settings JS globals. | |
| 220 | 206 | |
| 221 | -= 4.3.1 = | |
| 207 | +**Fixed** | |
| 222 | 208 | |
| 223 | -*Release Date - 6 June 2026* | |
| 209 | +* View tracking was lost during quick navigation or browser back-button restores. | |
| 210 | +* View counts were recorded for prerendered or initially hidden pages. | |
| 211 | +* Bot views were recorded from cached pages, and views were recorded for browser prefetches, prerenders and direct navigations to tracker URLs. | |
| 212 | +* Tracker scripts did not run when loaded asynchronously after `DOMContentLoaded` had fired. | |
| 213 | +* Generated output cache keys were not discoverable by the Clear Cache tools or the WP-CLI cache flush command. | |
| 214 | +* Settings on a multisite network read another site's values in the same request after a `switch_to_blog()` call, when read via `tptn_get_option()` or the global `$tptn_settings`. | |
| 215 | +* `tptn_get_settings()` returned `false` instead of an empty array when no settings had been saved yet. | |
| 216 | +* Visit data was silently lost in funnel aggregation, and the Fast Tracker raised an undefined array key warning. | |
| 217 | +* Plugin data was deleted when uninstalling one version while its paired free or Pro counterpart was active. | |
| 218 | +* Improved compatibility with PHP 8.6. | |
| 219 | +* [Pro] Daily counts in the `wp top10 popular` command did not respect the selected custom date range. | |
| 224 | 220 | |
| 225 | -* Improvements: | |
| 226 | - * Aggregation cron now runs every 2 minutes instead of 5 minutes for faster count updates. | |
| 227 | - * Sync Funnel now shows distinct error messages for an empty funnel, a lock conflict, and database failures (including the actual database error). | |
| 228 | - * Dashboard chart now formats large numbers with K/M abbreviations (e.g. 15,437 → 15.4K) and auto-hides overlapping bar labels. | |
| 229 | - * "Recreate Database Tables" in Tools now also recreates the visits funnel and visits log tables. | |
| 230 | - * [Pro] `wp top10 db recreate-tables` now accepts `--table=funnel` and `--table=log` in addition to `overall`, `daily`, and `all`. | |
| 221 | += Earlier versions = | |
| 231 | 222 | |
| 232 | -* Fixed: | |
| 233 | - * Sync Funnel on WordPress Playground (SQLite) incorrectly reported "another aggregation is in progress" due to unreliable SQLite detection; the `DATABASE_TYPE` constant is now checked first. | |
| 234 | - * Uninstalling the plugin no longer throws a fatal error when attempting to drop database tables; the path to the uninstaller was resolving one level above the plugin directory. | |
| 235 | - * "Recreate Database Tables" silently left the daily table missing due to a stale static cache in the table-installed check; all four tables are now recreated reliably. | |
| 223 | +For the changelog of earlier versions, please refer to the [releases page on GitHub](https://github.com/WebberZone/top-10/releases). | |
| 236 | 224 | |
| 237 | -= 4.3.0 = | |
| 225 | +== Upgrade Notice == | |
| 238 | 226 | |
| 239 | -*Release Date - 28 May 2026* | |
| 227 | += 4.5.1 = | |
| 228 | +Security release. Fixes a stored Cross-Site Scripting vulnerability that could be exploited by users with Author-level access or above. Update immediately. | |
| 240 | 229 | |
| 241 | -* [Release announcement](https://webberzone.com/announcements/top-10-v4-3-0/) | |
| 242 | - | |
| 243 | -* New: | |
| 244 | - * Buffered visit tracking: page views are queued in a funnel table and aggregated every 5 minutes, reducing write contention on busy sites. | |
| 245 | - * [Pro] RSS/Atom feed views are now counted. Enable under Counter settings > Track feed views. | |
| 246 | - * [Pro] Dashboard At a Glance widget now shows views for the current hour and today. | |
| 247 | - * [Pro] Full `wp top10` WP-CLI suite: counts, database, cache, settings, cron, and popular posts commands. All destructive commands support `--dry-run` and `--force`; multisite commands support `--network` and `--blog-id`. | |
| 248 | - | |
| 249 | -* Improvements: | |
| 250 | - * Scheduled maintenance deletes old daily rows in batches to prevent timeouts on large databases. | |
| 251 | - * New index on the daily table speeds up maintenance queries. Apply it to existing installs via Recreate Primary Key under Tools. | |
| 252 | - | |
| 253 | -* Fixed: | |
| 254 | - * Cache setting was referencing the wrong key, preventing posts from ever being cached. | |
| 255 | - * Database version was recorded before upgrade routines ran, causing upgrades to be silently skipped on re-activation. | |
| 256 | - * Daily queries now work on MySQL servers with ONLY_FULL_GROUP_BY enabled. | |
| 257 | - * Posts with identical counts now display in a consistent order when paginated. | |
| 258 | - * Daily counts now use the site's configured timezone instead of server time. | |
| 259 | - * Dashboard "Total visits" now matches the chart total rather than summing only the top 20 posts. | |
| 260 | - * Popular posts ordering no longer overridden by Post Types Order and similar plugins. | |
| 261 | - * Deactivation now clears both cron jobs and sets the settings option to not autoload. | |
| 262 | - * Removed incorrect `wpmu_drop_tables` filter that tried to drop network-wide tables on site deletion. | |
| 263 | - | |
| 264 | -= 4.2.3 = | |
| 265 | - | |
| 266 | -* Security: | |
| 267 | - * Hardened Settings API and metabox output escaping. | |
| 268 | - | |
| 269 | -* Improvements: | |
| 270 | - * Updated Freemius SDK to version 2.13.1. | |
| 271 | - * Updated Settings API assets and Tom Select handling. | |
| 272 | - * Refreshed translations and generated assets. | |
| 273 | - | |
| 274 | -* Fixes: | |
| 275 | - * Fixed metabox screen handling when `get_current_screen()` is unavailable. | |
| 276 | - * Fixed admin notices package tags. | |
| 277 | - | |
| 278 | -= 4.2.2 = | |
| 279 | - | |
| 280 | -* Modifications: | |
| 281 | - * Taxonomy Suggest script removed from Settings API. Metabox also uses Tom Select for the lookup of the category field in CRP Pro. | |
| 282 | - | |
| 283 | -* Fixes: | |
| 284 | - * CSS improvements for left-thumbs and grid-thumbs styles. | |
| 285 | - | |
| 286 | -= 4.2.1 = | |
| 287 | - | |
| 288 | -* Security: | |
| 289 | - * Fixed REST API permission checks to prevent unauthorized exposure of post passwords in edit context. | |
| 290 | - | |
| 291 | -* Fixes: | |
| 292 | - * Fixed a bug with the "Clear cache" button in the Tools page. | |
| 293 | - * Fixed thumbnail location restrictions to properly support Grid thumbnails style in addition to Left thumbnails. | |
| 294 | - * Improved JavaScript logic for style-based thumbnail location validation with better error handling and fallback mechanisms. | |
| 295 | - | |
| 296 | -= 4.2.0 = | |
| 297 | - | |
| 298 | -Release post: [https://webberzone.com/announcements/top-10-v4-2-0/](https://webberzone.com/announcements/top-10-v4-2-0/) | |
| 299 | - | |
| 300 | -* New: | |
| 301 | - * Settings wizard to guide initial configuration and review existing settings | |
| 302 | - * Network-wide dashboard with aggregated multisite statistics | |
| 303 | - * [Pro] High-traffic tracking mode with status validation panel | |
| 304 | - * [Pro] Copy settings between multisite network sites | |
| 305 | - * [Pro] Compact “Top 10 Views Overview” dashboard widget | |
| 306 | - * [Pro] Option to disable the Admin Bar menu | |
| 307 | - * [Pro] Maintenance setting to override data retention period | |
| 308 | - | |
| 309 | -* Improvements: | |
| 310 | - * [Pro] Improved dashboard chart bar click-through to open the Popular Posts screen filtered to that day | |
| 311 | - * Updated Settings API to version 2.7.1 | |
| 312 | - * Improved media handler with recursion protection and more robust processing | |
| 313 | - * Media Handler now supports the FIFU WordPress plugin for featured image detection. | |
| 314 | - * Improved Tools page statistics display and caching | |
| 315 | - * Wrapped Import/Export and Tools sections in postbox containers for consistent UI | |
| 316 | - | |
| 317 | -* Developer / Internal: | |
| 318 | - * Refactored popular posts queries for improved performance and WordPress VIP compatibility | |
| 319 | - * Updated caching behaviour for dynamic exclusions | |
| 320 | - * Refactored database operations into a dedicated Database class | |
| 321 | - * Updated Freemius SDK to version 2.13.0 | |
| 322 | - | |
| 323 | -* Fixes: | |
| 324 | - * Fixed `Top_Ten_Query` handling of the `date_query` argument | |
| 325 | - * Fixed activation redirects on single-site installs within multisite networks | |
| 326 | - * Fixed `exclude_current_post` behaviour when caching is enabled | |
| 327 | - * Fixed live-edit count updates in multisite statistics | |
| 328 | - | |
| 329 | -== Upgrade Notice == | |
| 330 | - | |
| 331 | -= 4.4.1 = | |
| 332 | -Fixes the "Exclude Front page and Posts page" setting having no effect, and a settings page sidebar/tab overlap. No action required. | |
| 230 | += 4.5.0 = | |
| 231 | +Adds page builder elements, site-wide tracking and a daily-table rollup tool. Fixes several cases of lost view counts and cuts admin overhead on large multisite networks. | |