[ Index ]

PHP Cross Reference of BuddyPress

title

Body

[close]

/src/bp-templates/bp-legacy/buddypress/members/single/ -> messages.php (source)

   1  <?php
   2  /**
   3   * BuddyPress - Users Messages
   4   *
   5   * @package BuddyPress
   6   * @subpackage bp-legacy
   7   * @version 3.0.0
   8   */
   9  
  10  ?>
  11  
  12  <div class="item-list-tabs no-ajax" id="subnav" aria-label="<?php esc_attr_e( 'Member secondary navigation', 'buddypress' ); ?>" role="navigation">
  13      <ul>
  14  
  15          <?php bp_get_options_nav(); ?>
  16  
  17      </ul>
  18  
  19      <?php if ( bp_is_messages_inbox() || bp_is_messages_sentbox() ) : ?>
  20  
  21          <div class="message-search"><?php bp_message_search_form(); ?></div>
  22  
  23      <?php endif; ?>
  24  
  25  </div><!-- .item-list-tabs -->
  26  
  27  <?php
  28  switch ( bp_current_action() ) :
  29  
  30      // Inbox/Sentbox
  31      case 'inbox'   :
  32      case 'sentbox' :
  33  
  34          /**
  35           * Fires before the member messages content for inbox and sentbox.
  36           *
  37           * @since 1.2.0
  38           */
  39          do_action( 'bp_before_member_messages_content' ); ?>
  40  
  41          <?php if ( bp_is_messages_inbox() ) : ?>
  42              <h2 class="bp-screen-reader-text"><?php
  43                  /* translators: accessibility text */
  44                  _e( 'Messages inbox', 'buddypress' );
  45              ?></h2>
  46          <?php elseif ( bp_is_messages_sentbox() ) : ?>
  47              <h2 class="bp-screen-reader-text"><?php
  48                  /* translators: accessibility text */
  49                  _e( 'Sent Messages', 'buddypress' );
  50              ?></h2>
  51          <?php endif; ?>
  52  
  53          <div class="messages">
  54              <?php bp_get_template_part( 'members/single/messages/messages-loop' ); ?>
  55          </div><!-- .messages -->
  56  
  57          <?php
  58  
  59          /**
  60           * Fires after the member messages content for inbox and sentbox.
  61           *
  62           * @since 1.2.0
  63           */
  64          do_action( 'bp_after_member_messages_content' );
  65          break;
  66  
  67      // Single Message View
  68      case 'view' :
  69          bp_get_template_part( 'members/single/messages/single' );
  70          break;
  71  
  72      // Compose
  73      case 'compose' :
  74          bp_get_template_part( 'members/single/messages/compose' );
  75          break;
  76  
  77      // Sitewide Notices
  78      case 'notices' :
  79  
  80          /**
  81           * Fires before the member messages content for notices.
  82           *
  83           * @since 1.2.0
  84           */
  85          do_action( 'bp_before_member_messages_content' ); ?>
  86  
  87          <h2 class="bp-screen-reader-text"><?php
  88              /* translators: accessibility text */
  89              _e( 'Sitewide Notices', 'buddypress' );
  90          ?></h2>
  91  
  92          <div class="messages">
  93              <?php bp_get_template_part( 'members/single/messages/notices-loop' ); ?>
  94          </div><!-- .messages -->
  95  
  96          <?php
  97  
  98          /**
  99           * Fires after the member messages content for inbox and sentbox.
 100           *
 101           * @since 1.2.0
 102           */
 103          do_action( 'bp_after_member_messages_content' );
 104          break;
 105  
 106      // Any other
 107      default :
 108          bp_get_template_part( 'members/single/plugins' );
 109          break;
 110  endswitch;


Generated: Tue Dec 10 01:01:39 2019 Cross-referenced by PHPXref 0.7.1