Fix Category Count
Fix Category Count
Description
This plugin will allow you to easily repair and fix your category count for posts, pages and custom post types
You may fix specific or all post type categories that you believe are incorrect.
It is always recommended that you have a backup of your database.
Possible Upcoming Features
- Show a report after completion of tables updated
Please Read
If you like, or hate this plugin, please rate it on WordPress. If you are having any issues with it, please leave a comment on the plugin page.
Installation
- To install this plugin, either upload the entire directory to your wp-content/plugins/ directory, upload the zip file in your admin plugins screen. You may also install the plugin through wordpress.org
- Activate the plugin through the ‘Plugins’ menu in WordPress
- The plugin may be found in the admin menu under Tools
Faq
Why does the category count get messed up?
That is a great question.
Reviews
Broken
By davemc50 on August 5, 2024
WordPress 6.x , no longer works, "There has been a critical error on this website"
Nice!
By Gustav (4ever16) on July 26, 2018
Not good for large sites I think
By deadhippo on December 29, 2017
9300 rows affected. (Query took 2.9573 seconds.)
UPDATE wp_term_taxonomy SET count = (
SELECT COUNT(*) FROM wp_term_relationships rel
LEFT JOIN wp_posts po ON (po.ID = rel.object_id)
WHERE
rel.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id
AND
wp_term_taxonomy.taxonomy NOT IN ('link_category')
AND
po.post_status IN ('publish', 'future')
)
Source: https://stackoverflow.com/questions/18669256/how-to-update-wordpress-taxonomiescategories-tags-count-field-after-bulk-impoMany thanks!!!
By trongnghia203 on September 20, 2017
Simple and works like a charm.
By alburse on April 9, 2017
Great Plugin
By Marinos (HelpPost.gr) on September 3, 2016
Thanks !!!!!
good tool
By Mike V. Gorbunov (michael_zloi) on September 3, 2016
a must have for fixing the import bugs
Super easy and quick
By wpisawesome on September 3, 2016
Thanks! This plugin saved me a lot of time trying to do this manually. Simply. effective. Bravo.
Changelog
1.2
- This now works on the latest version of WordPress
1.1
- Updated for WordPress 5.0+ and PHP 7.4+
- Fixed all SQL injection vulnerabilities using prepared statements
- Added proper input sanitization and output escaping
- Fixed security issues with nonce verification
- Improved code quality and WordPress coding standards compliance
- Fixed bug in update_category_correct_count method
- Added proper capability checks
- Replaced short tags with proper PHP tags
- Added text domain for internationalization
1.0
- Initial Development


