| 1 | <?php |
|---|
| 2 | |
|---|
| 3 | /** |
|---|
| 4 | * BuddyPress - Members Loop |
|---|
| 5 | * |
|---|
| 6 | * Querystring is set via AJAX in _inc/ajax.php - bp_legacy_theme_object_filter() |
|---|
| 7 | * |
|---|
| 8 | * @package BuddyPress |
|---|
| 9 | * @subpackage bp-legacy |
|---|
| 10 | */ |
|---|
| 11 | |
|---|
| 12 | ?> |
|---|
| 13 | |
|---|
| 14 | <?php do_action( 'bp_before_group_members_content' ); ?> |
|---|
| 15 | |
|---|
| 16 | <?php if ( bp_group_has_members( bp_ajax_querystring( 'groupmembers' ) ) ) : ?> |
|---|
| 17 | |
|---|
| 18 | <div id="pag-top" class="pagination"> |
|---|
| 19 | |
|---|
| 20 | <div class="pag-count" id="groupmembers-count-top"> |
|---|
| 21 | |
|---|
| 22 | <?php bp_members_pagination_count(); ?> |
|---|
| 23 | |
|---|
| 24 | </div> |
|---|
| 25 | |
|---|
| 26 | <div class="pagination-links" id="groupmembers-pag-top"> |
|---|
| 27 | |
|---|
| 28 | <?php bp_members_pagination_links(); ?> |
|---|
| 29 | |
|---|
| 30 | </div> |
|---|
| 31 | |
|---|
| 32 | </div> |
|---|
| 33 | |
|---|
| 34 | <?php do_action( 'bp_before_directory_members_list' ); ?> |
|---|
| 35 | |
|---|
| 36 | <ul id="members-list" class="item-list" role="main"> |
|---|
| 37 | |
|---|
| 38 | <?php while ( bp_group_members() ) : bp_group_the_member(); ?> |
|---|
| 39 | |
|---|
| 40 | <?php if( bp_is_group_admin_screen( 'manage-members' ) ) :?> |
|---|
| 41 | |
|---|
| 42 | <li class="<?php bp_group_member_css_class(); ?>"> |
|---|
| 43 | <div class="item-avatar"> |
|---|
| 44 | <?php bp_group_member_avatar_mini(); ?> |
|---|
| 45 | </div> |
|---|
| 46 | |
|---|
| 47 | <div class="item"> |
|---|
| 48 | <div class="item-title"> |
|---|
| 49 | <?php bp_group_member_link(); ?> |
|---|
| 50 | |
|---|
| 51 | <?php if ( bp_get_group_member_is_banned() ) _e( '(banned)', 'buddypress' ); ?> |
|---|
| 52 | |
|---|
| 53 | </div> |
|---|
| 54 | |
|---|
| 55 | </div> |
|---|
| 56 | |
|---|
| 57 | <div class="action"> |
|---|
| 58 | |
|---|
| 59 | <span class="small"> |
|---|
| 60 | |
|---|
| 61 | <?php if ( bp_get_group_member_is_banned() ) : ?> |
|---|
| 62 | |
|---|
| 63 | <a href="<?php bp_group_member_unban_link(); ?>" class="button confirm member-unban" title="<?php _e( 'Unban this member', 'buddypress' ); ?>"><?php _e( 'Remove Ban', 'buddypress' ); ?></a> |
|---|
| 64 | |
|---|
| 65 | <?php else : ?> |
|---|
| 66 | |
|---|
| 67 | <a href="<?php bp_group_member_ban_link(); ?>" class="button confirm member-ban" title="<?php _e( 'Kick and ban this member', 'buddypress' ); ?>"><?php _e( 'Kick & Ban', 'buddypress' ); ?></a> |
|---|
| 68 | <a href="<?php bp_group_member_promote_mod_link(); ?>" class="button confirm member-promote-to-mod" title="<?php _e( 'Promote to Mod', 'buddypress' ); ?>"><?php _e( 'Promote to Mod', 'buddypress' ); ?></a> |
|---|
| 69 | <a href="<?php bp_group_member_promote_admin_link(); ?>" class="button confirm member-promote-to-admin" title="<?php _e( 'Promote to Admin', 'buddypress' ); ?>"><?php _e( 'Promote to Admin', 'buddypress' ); ?></a> |
|---|
| 70 | |
|---|
| 71 | <?php endif; ?> |
|---|
| 72 | |
|---|
| 73 | <a href="<?php bp_group_member_remove_link(); ?>" class="button confirm" title="<?php _e( 'Remove this member', 'buddypress' ); ?>"><?php _e( 'Remove from group', 'buddypress' ); ?></a> |
|---|
| 74 | |
|---|
| 75 | <?php do_action( 'bp_group_manage_members_admin_item' ); ?> |
|---|
| 76 | |
|---|
| 77 | </span> |
|---|
| 78 | |
|---|
| 79 | </div> |
|---|
| 80 | |
|---|
| 81 | <div class="clear"></div> |
|---|
| 82 | </li> |
|---|
| 83 | |
|---|
| 84 | <?php else :?> |
|---|
| 85 | |
|---|
| 86 | <li> |
|---|
| 87 | <div class="item-avatar"> |
|---|
| 88 | <a href="<?php bp_group_member_domain(); ?>"><?php bp_group_member_avatar_thumb(); ?></a> |
|---|
| 89 | </div> |
|---|
| 90 | |
|---|
| 91 | <div class="item"> |
|---|
| 92 | <div class="item-title"> |
|---|
| 93 | <?php bp_group_member_link(); ?> |
|---|
| 94 | |
|---|
| 95 | <span class="update"> <?php bp_group_member_joined_since(); ?></span> |
|---|
| 96 | |
|---|
| 97 | </div> |
|---|
| 98 | |
|---|
| 99 | <?php do_action( 'bp_group_members_list_item' ); ?> |
|---|
| 100 | |
|---|
| 101 | </div> |
|---|
| 102 | |
|---|
| 103 | <?php if ( bp_is_active( 'friends' ) ) : ?> |
|---|
| 104 | |
|---|
| 105 | <div class="action"> |
|---|
| 106 | |
|---|
| 107 | <?php bp_add_friend_button( bp_get_group_member_id(), bp_get_group_member_is_friend() ); ?> |
|---|
| 108 | |
|---|
| 109 | <?php do_action( 'bp_group_members_list_item_action' ); ?> |
|---|
| 110 | |
|---|
| 111 | </div> |
|---|
| 112 | |
|---|
| 113 | <?php endif; ?> |
|---|
| 114 | |
|---|
| 115 | <div class="clear"></div> |
|---|
| 116 | </li> |
|---|
| 117 | |
|---|
| 118 | <?php endif;?> |
|---|
| 119 | |
|---|
| 120 | <?php endwhile; ?> |
|---|
| 121 | |
|---|
| 122 | </ul> |
|---|
| 123 | |
|---|
| 124 | <?php do_action( 'bp_after_group_members_list' ); ?> |
|---|
| 125 | |
|---|
| 126 | <div id="pag-bottom" class="pagination"> |
|---|
| 127 | |
|---|
| 128 | <div class="pag-count" id="groupmembers-count-bottom"> |
|---|
| 129 | |
|---|
| 130 | <?php bp_members_pagination_count(); ?> |
|---|
| 131 | |
|---|
| 132 | </div> |
|---|
| 133 | |
|---|
| 134 | <div class="pagination-links" id="groupmembers-pag-bottom"> |
|---|
| 135 | |
|---|
| 136 | <?php bp_members_pagination_links(); ?> |
|---|
| 137 | |
|---|
| 138 | </div> |
|---|
| 139 | |
|---|
| 140 | </div> |
|---|
| 141 | |
|---|
| 142 | <?php do_action( 'bp_after_group_members_content' ); ?> |
|---|
| 143 | |
|---|
| 144 | <?php else: ?> |
|---|
| 145 | |
|---|
| 146 | <div id="message" class="info"> |
|---|
| 147 | <p><?php _e( 'This group has no members.', 'buddypress' ); ?></p> |
|---|
| 148 | </div> |
|---|
| 149 | |
|---|
| 150 | <?php endif; ?> |
|---|
| 151 | |
|---|
| 152 | <?php do_action( 'bp_after_group_members_loop' ); ?> |
|---|