/bp-templates/bp-legacy/buddypress/members/single/friends/requests.php

  1. <?php 
  2. /** 
  3. * BuddyPress - Members Friends Requests 
  4. * 
  5. * @package BuddyPress 
  6. * @subpackage bp-legacy 
  7. */ 
  8.  
  9. /** 
  10. * Fires before the display of member friend requests content. 
  11. * 
  12. * @since 1.2.0 
  13. */ 
  14. do_action( 'bp_before_member_friend_requests_content' ); ?> 
  15.  
  16. <?php if ( bp_has_members( 'type=alphabetical&include=' . bp_get_friendship_requests() ) ) : ?> 
  17.  
  18. <h2 class="bp-screen-reader-text"><?php 
  19. /** translators: accessibility text */ 
  20. _e( 'Friendship requests', 'buddypress' ); 
  21. ?></h2> 
  22.  
  23. <div id="pag-top" class="pagination no-ajax"> 
  24.  
  25. <div class="pag-count" id="member-dir-count-top"> 
  26.  
  27. <?php bp_members_pagination_count(); ?> 
  28.  
  29. </div> 
  30.  
  31. <div class="pagination-links" id="member-dir-pag-top"> 
  32.  
  33. <?php bp_members_pagination_links(); ?> 
  34.  
  35. </div> 
  36.  
  37. </div> 
  38.  
  39. <ul id="friend-list" class="item-list"> 
  40. <?php while ( bp_members() ) : bp_the_member(); ?> 
  41.  
  42. <li id="friendship-<?php bp_friend_friendship_id(); ?>"> 
  43. <div class="item-avatar"> 
  44. <a href="<?php bp_member_link(); ?>"><?php bp_member_avatar(); ?></a> 
  45. </div> 
  46.  
  47. <div class="item"> 
  48. <div class="item-title"><a href="<?php bp_member_link(); ?>"><?php bp_member_name(); ?></a></div> 
  49. <div class="item-meta"><span class="activity"><?php bp_member_last_active(); ?></span></div> 
  50.  
  51. <?php 
  52. /** 
  53. * Fires inside the display of a member friend request item. 
  54. * 
  55. * @since 1.1.0 
  56. */ 
  57. do_action( 'bp_friend_requests_item' ); 
  58. ?> 
  59. </div> 
  60.  
  61. <div class="action"> 
  62. <a class="button accept" href="<?php bp_friend_accept_request_link(); ?>"><?php _e( 'Accept', 'buddypress' ); ?></a>   
  63. <a class="button reject" href="<?php bp_friend_reject_request_link(); ?>"><?php _e( 'Reject', 'buddypress' ); ?></a> 
  64.  
  65. <?php 
  66.  
  67. /** 
  68. * Fires inside the member friend request actions markup. 
  69. * 
  70. * @since 1.1.0 
  71. */ 
  72. do_action( 'bp_friend_requests_item_action' ); ?> 
  73. </div> 
  74. </li> 
  75.  
  76. <?php endwhile; ?> 
  77. </ul> 
  78.  
  79. <?php 
  80.  
  81. /** 
  82. * Fires and displays the member friend requests content. 
  83. * 
  84. * @since 1.1.0 
  85. */ 
  86. do_action( 'bp_friend_requests_content' ); ?> 
  87.  
  88. <div id="pag-bottom" class="pagination no-ajax"> 
  89.  
  90. <div class="pag-count" id="member-dir-count-bottom"> 
  91.  
  92. <?php bp_members_pagination_count(); ?> 
  93.  
  94. </div> 
  95.  
  96. <div class="pagination-links" id="member-dir-pag-bottom"> 
  97.  
  98. <?php bp_members_pagination_links(); ?> 
  99.  
  100. </div> 
  101.  
  102. </div> 
  103.  
  104. <?php else: ?> 
  105.  
  106. <div id="message" class="info"> 
  107. <p><?php _e( 'You have no pending friendship requests.', 'buddypress' ); ?></p> 
  108. </div> 
  109.  
  110. <?php endif;?> 
  111.  
  112. <?php 
  113.  
  114. /** 
  115. * Fires after the display of member friend requests content. 
  116. * 
  117. * @since 1.2.0 
  118. */ 
  119. do_action( 'bp_after_member_friend_requests_content' ); ?> 
.