Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/29/2010 03:50:17 AM (15 years ago)
Author:
johnjamesjacoby
Message:

Fixes #2251

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/1.2/bp-forums/bp-forums-templatetags.php

    r2972 r2975  
    667667    global $bp, $forum_template;
    668668
    669     $from_num = bp_core_number_format( intval( ( $forum_template->pag_page - 1 ) * $forum_template->pag_num ) + 1 );
    670     $to_num = bp_core_number_format( ( $from_num + ( $forum_template->pag_num - 1  ) > $forum_template->total_topic_count ) ? $forum_template->total_topic_count : $from_num + ( $forum_template->pag_num - 1 ) );
     669    $start_num = intval( ( $forum_template->pag_page - 1 ) * $forum_template->pag_num ) + 1;
     670    $from_num = bp_core_number_format( $start_num );
     671    $to_num = bp_core_number_format( ( $start_num + ( $forum_template->pag_num - 1  ) > $forum_template->total_topic_count ) ? $forum_template->total_topic_count : $start_num + ( $forum_template->pag_num - 1 ) );
    671672    $total = bp_core_number_format( $forum_template->total_topic_count );
    672673
     
    675676        $pag_filter = sprintf( __( ' matching tag "%s"', 'buddypress' ), $forum_template->search_terms );
    676677
    677     echo apply_filters( 'bp_forum_pagination_count', sprintf( __( 'Viewing topic %s to %s (%s total topics%s)', 'buddypress' ), $from_num, $to_num, $total, $pag_filter ) );
     678    echo apply_filters( 'bp_forum_pagination_count', sprintf( __( 'Viewing topic %1$s to %2$s (%3$s total topics%4$s)', 'buddypress' ), $from_num, $to_num, $total, $pag_filter ) );
    678679?>
    679680<span class="ajax-loader"></span>
     
    985986    global $bp, $topic_template;
    986987
    987     $from_num = intval( ( $topic_template->pag_page - 1 ) * $topic_template->pag_num ) + 1;
    988     $to_num = ( $from_num + ( $topic_template->pag_num - 1  ) > $topic_template->total_post_count ) ? $topic_template->total_post_count : $from_num + ( $topic_template->pag_num - 1 );
    989 
    990     echo apply_filters( 'bp_the_topic_pagination_count', sprintf( __( 'Viewing post %d to %d (%d total posts)', 'buddypress' ), $from_num, $to_num, $topic_template->total_post_count ) );
     988    $start_num = intval( ( $topic_template->pag_page - 1 ) * $topic_template->pag_num ) + 1;
     989    $from_num = bp_core_number_format( $start_num );
     990    $to_num = bp_core_number_format( ( $start_num + ( $topic_template->pag_num - 1  ) > $topic_template->total_post_count ) ? $topic_template->total_post_count : $start_num + ( $topic_template->pag_num - 1 ) );
     991    $total = bp_core_number_format( $topic_template->total_post_count );
     992
     993    echo apply_filters( 'bp_the_topic_pagination_count', sprintf( __( 'Viewing post %1$s to %2$s (%3$s total posts)', 'buddypress' ), $from_num, $to_num, $total ) );
    991994?>
    992995    <span class="ajax-loader"></span>
Note: See TracChangeset for help on using the changeset viewer.