bbp_get_forum_post_count
Description
The ‘bbp_get_forum_post_count’ function is used to return the total count of all replies to topics within a forum and sub forums
How to use it
<?php bbp_get_forum_post_count( $forum_id, $total_count ); ?>
$forum_id (optional) – Returns count for particular forum id
$total_count (optional) – Returns total count for all replies in forum and sub forums by default or if true, otherwise returns total count for all replies in a forum not including replies in subforum(s)
Used in bbp_forum_post_count()
Sample code example
<?php $value = bbp_get_forum_post_count(); echo $value; ?>
Returns the total count of all replies within a forum and sub forums
<?php $value = bbp_get_forum_post_count( '', false ); echo $value; ?>
Returns the count of all replies within a forum excluding sub forums of parent forum