Support › General › How to get post number
I got 3 custom post types
How to get the number of post included in each type? what the php function that will excecute?
<?php // Get total number of posts in "Books" post type
$count_books = wp_count_posts('books');
$total_books = $count_books->publish;
echo $total_books . ' books. ';