How to know the total number of posts in a category and its subcategories (wordpress)?
It would seem the task is simple, but the solutions can not.
March 20th 20 at 11:20
Kaka clicking on the redirect button to the edit form?
Layout breaks on safari how can I fix it?
How to catch the image size and position it on the object?
As in vuejs to do the rendering of the specified number of times?
ASP.NET Core. JWT. How to revoke a token?
How to automatically turn on battery saver when it enters standby mode?
What is the cause of the error "Out of shared memory: You might need to increase max_locks_per_transaction"?
How to grid make the width of the cell was selected based on the text inside?
More answers about
"How to know the total number of posts in a category and its subcategories (wordpress)?"
March 20th 20 at 11:22
Thank you! This is what you need.
commented on March 20th 20 at 11:25
March 20th 20 at 11:24
wp_count_posts() - Gets the number of records in any record type and any status (published, draft).
Here you can read and an example of usage is
Function wp_count_posts() does not allow to work with a specific category.
commented on March 20th 20 at 11:27
Find more questions by tags