Advertisement
rdusnr

Untitled

Aug 31st, 2017
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.10 KB | None | 0 0
  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. * Fires before the display of the members loop.
  14. *
  15. * @since 1.2.0
  16. */
  17. do_action( 'bp_before_members_loop' ); ?>
  18.  
  19. <?php if ( bp_get_current_member_type() ) : ?>
  20. <p class="current-member-type"><?php bp_current_member_type_message() ?></p>
  21. <?php endif; ?>
  22.  
  23. <?php if ( bp_has_members( bp_ajax_querystring( 'members' ). '&per_page='.sq_option('bp_members_perpage', 24) . '&type=alphabetical' ) ) : ?>
  24.  
  25. <div id="pag-top" class="pagination">
  26.  
  27. <div class="pag-count" id="member-dir-count-top">
  28.  
  29. <?php bp_members_pagination_count(); ?>
  30.  
  31. </div>
  32.  
  33. <div class="pagination-links" id="member-dir-pag-top">
  34.  
  35. <?php bp_members_pagination_links(); ?>
  36.  
  37. </div>
  38.  
  39. </div>
  40.  
  41. <?php
  42.  
  43. /**
  44. * Fires before the display of the members list.
  45. *
  46. * @since 1.1.0
  47. */
  48. do_action( 'bp_before_directory_members_list' ); ?>
  49.  
  50. <ul id="members-list" class="item-list row kleo-isotope masonry" aria-live="assertive" aria-relevant="all">
  51.  
  52. <?php while ( bp_members() ) : bp_the_member(); ?>
  53.  
  54. <li class="kleo-masonry-item">
  55. <div class="member-inner-list animated animate-when-almost-visible bottom-to-top">
  56. <div class="item-avatar rounded">
  57. <a href="<?php bp_member_permalink(); ?>"><?php bp_member_avatar(); ?></a>
  58. <?php do_action('bp_member_online_status', bp_get_member_user_id()); ?>
  59. </div>
  60.  
  61. <div class="item">
  62. <div class="item-title">
  63. <a href="<?php bp_member_permalink(); ?>"><?php bp_member_name(); ?></a>
  64. </div>
  65.  
  66. <?php if(function_exists( 'bp_core_iso8601_date' )) : ?>
  67. <div class="item-meta"><span class="activity" data-livestamp="<?php bp_core_iso8601_date( bp_get_member_last_active( array( 'relative' => false ) ) ); ?>"><?php bp_member_last_active(); ?></span></div>
  68. <?php else: ?>
  69. <div class="item-meta"><span class="activity"><?php bp_member_last_active(); ?></span></div>
  70. <?php endif; ?>
  71.  
  72. <?php if ( bp_get_member_latest_update() ) : ?>
  73. <span class="update"> <?php bp_member_latest_update(); ?></span>
  74. <?php endif; ?>
  75.  
  76. <?php
  77.  
  78. /**
  79. * Fires inside the display of a directory member item.
  80. *
  81. * @since 1.1.0
  82. */
  83. do_action( 'bp_directory_members_item' ); ?>
  84.  
  85. <?php
  86. /***
  87. * If you want to show specific profile fields here you can,
  88. * but it'll add an extra query for each member in the loop
  89. * (only one regardless of the number of fields you show):
  90. *
  91. * bp_member_profile_data( 'field=the field name' );
  92. */
  93. ?>
  94. </div>
  95.  
  96. <div class="action">
  97.  
  98. <?php
  99.  
  100. /**
  101. * Fires inside the members action HTML markup to display actions.
  102. *
  103. * @since 1.1.0
  104. */
  105. do_action( 'bp_directory_members_actions' ); ?>
  106.  
  107. </div>
  108.  
  109. </div><!--end member-inner-list-->
  110. </li>
  111.  
  112. <?php endwhile; ?>
  113.  
  114. </ul>
  115.  
  116. <?php
  117.  
  118. /**
  119. * Fires after the display of the members list.
  120. *
  121. * @since 1.1.0
  122. */
  123. do_action( 'bp_after_directory_members_list' ); ?>
  124.  
  125. <?php bp_member_hidden_fields(); ?>
  126.  
  127. <div id="pag-bottom" class="pagination">
  128.  
  129. <div class="pag-count" id="member-dir-count-bottom">
  130.  
  131. <?php bp_members_pagination_count(); ?>
  132.  
  133. </div>
  134.  
  135. <div class="pagination-links" id="member-dir-pag-bottom">
  136.  
  137. <?php bp_members_pagination_links(); ?>
  138.  
  139. </div>
  140.  
  141. </div>
  142.  
  143. <?php else: ?>
  144.  
  145. <div id="message" class="info">
  146. <p><?php _e( "Sorry, no members were found.", 'buddypress' ); ?></p>
  147. </div>
  148.  
  149. <?php endif; ?>
  150.  
  151. <?php
  152.  
  153. /**
  154. * Fires after the display of the members loop.
  155. *
  156. * @since 1.2.0
  157. */
  158. do_action( 'bp_after_members_loop' ); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement