Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/13/2012 04:31:51 PM (14 years ago)
Author:
boonebgorges
Message:

'Total member count' cleanup:

  • Introduces bp_core_get_active_member_count() to get an accurate count of members with recorded last_activity
  • Points bp_get_total_member_count() to bp_core_get_active_member_count(), so that 'All Members' tab count on member directories matches the total count prepared by BP_Core_User::get_users(). Fixes #4061
  • Changes 'All Members' count in activity/index.php to use bp_get_total_member_count(), for greater accuracy and consistency between activity and members components
  • Introduces a cache-busting function to be fired when member counts change (new members, spam status changed, member deleted)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-themes/bp-default/activity/index.php

    r5819 r5987  
    3737                                        <?php do_action( 'bp_before_activity_type_tab_all' ); ?>
    3838
    39                                         <li class="selected" id="activity-all"><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_activity_slug() ); ?>" title="<?php _e( 'The public activity for everyone on this site.', 'buddypress' ); ?>"><?php printf( __( 'All Members <span>%s</span>', 'buddypress' ), bp_get_total_site_member_count() ); ?></a></li>
     39                                        <li class="selected" id="activity-all"><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_activity_slug() ); ?>" title="<?php _e( 'The public activity for everyone on this site.', 'buddypress' ); ?>"><?php printf( __( 'All Members <span>%s</span>', 'buddypress' ), bp_get_total_member_count() ); ?></a></li>
    4040
    4141                                        <?php if ( is_user_logged_in() ) : ?>
     
    9090
    9191                                        <li id="activity-filter-select" class="last">
    92                                                 <label for="activity-filter-by"><?php _e( 'Show:', 'buddypress' ); ?></label> 
     92                                                <label for="activity-filter-by"><?php _e( 'Show:', 'buddypress' ); ?></label>
    9393                                                <select id="activity-filter-by">
    9494                                                        <option value="-1"><?php _e( 'Everything', 'buddypress' ); ?></option>
Note: See TracChangeset for help on using the changeset viewer.