bbp_get_topic_voice_count( int $topic_id,  $integer = false )

Return total voice count of a topic

Description

Parameters

$topic_id

(int) (Optional) Topic id

Return

(int) Members count of the topic

Source

File: bp-forums/topics/template.php

	function bbp_get_topic_voice_count( $topic_id = 0, $integer = false ) {
		$topic_id = bbp_get_topic_id( $topic_id );
		$voices   = (int) get_post_meta( $topic_id, '_bbp_voice_count', true );
		$filter   = ( true === $integer ) ? 'bbp_get_topic_voice_count_int' : 'bbp_get_topic_voice_count';

		return apply_filters( $filter, $voices, $topic_id );
	}

Changelog

Changelog
Version Description
bbPress (r2567) Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.