Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: comments_popup_link

@kawauso

Member

Something like:

function posts_number( $id = 0, $zero = false, $one = false, $more = false ) { // Port of WP's comments_number
$topic = get_topic( get_topic_id( $id ) );
$number = $topic->topic_posts;

if ( $number > 1 )
$output = str_replace('%', bb_number_format_i18n($number), ( false === $more ) ? __('% Posts') : $more);
elseif ( $number == 0 )
$output = ( false === $zero ) ? __('No Posts') : $zero;
else // must be one
$output = ( false === $one ) ? __('1 Post') : $one;

echo apply_filters('posts_number', $output, $number);
}

should work I think. Misread the original question slightly.

Skip to toolbar