Category and children post count
Checking Daniel Llewellyn code and WordPress’ WP_Query reference, I realized that we need to pass an array of array within the tax_query parameter. Otherwise, it’d just return all post counts. Here is the little modified code: if ( ! function_exists( ‘ipt_kb_total_cat_post_count’ ) ) : /** * Simple function to get category post count including all … Read more