[ Index ]

PHP Cross Reference of BBPress

title

Body

[close]

/src/templates/default/bbpress/ -> loop-single-topic.php (source)

   1  <?php
   2  
   3  /**
   4   * Topics Loop - Single
   5   *
   6   * @package bbPress
   7   * @subpackage Theme
   8   */
   9  
  10  // Exit if accessed directly
  11  defined( 'ABSPATH' ) || exit;
  12  
  13  ?>
  14  
  15  <ul id="bbp-topic-<?php bbp_topic_id(); ?>" <?php bbp_topic_class(); ?>>
  16      <li class="bbp-topic-title">
  17  
  18          <?php if ( bbp_is_user_home() ) : ?>
  19  
  20              <?php if ( bbp_is_favorites() ) : ?>
  21  
  22                  <span class="bbp-row-actions">
  23  
  24                      <?php do_action( 'bbp_theme_before_topic_favorites_action' ); ?>
  25  
  26                      <?php bbp_topic_favorite_link( array( 'before' => '', 'favorite' => '+', 'favorited' => '&times;' ) ); ?>
  27  
  28                      <?php do_action( 'bbp_theme_after_topic_favorites_action' ); ?>
  29  
  30                  </span>
  31  
  32              <?php elseif ( bbp_is_subscriptions() ) : ?>
  33  
  34                  <span class="bbp-row-actions">
  35  
  36                      <?php do_action( 'bbp_theme_before_topic_subscription_action' ); ?>
  37  
  38                      <?php bbp_topic_subscription_link( array( 'before' => '', 'subscribe' => '+', 'unsubscribe' => '&times;' ) ); ?>
  39  
  40                      <?php do_action( 'bbp_theme_after_topic_subscription_action' ); ?>
  41  
  42                  </span>
  43  
  44              <?php endif; ?>
  45  
  46          <?php endif; ?>
  47  
  48          <?php do_action( 'bbp_theme_before_topic_title' ); ?>
  49  
  50          <a class="bbp-topic-permalink" href="<?php bbp_topic_permalink(); ?>"><?php bbp_topic_title(); ?></a>
  51  
  52          <?php do_action( 'bbp_theme_after_topic_title' ); ?>
  53  
  54          <?php bbp_topic_pagination(); ?>
  55  
  56          <?php do_action( 'bbp_theme_before_topic_meta' ); ?>
  57  
  58          <p class="bbp-topic-meta">
  59  
  60              <?php do_action( 'bbp_theme_before_topic_started_by' ); ?>
  61  
  62              <span class="bbp-topic-started-by"><?php printf( esc_html__( 'Started by: %1$s', 'bbpress' ), bbp_get_topic_author_link( array( 'size' => '14' ) ) ); ?></span>
  63  
  64              <?php do_action( 'bbp_theme_after_topic_started_by' ); ?>
  65  
  66              <?php if ( ! bbp_is_single_forum() || ( bbp_get_topic_forum_id() !== bbp_get_forum_id() ) ) : ?>
  67  
  68                  <?php do_action( 'bbp_theme_before_topic_started_in' ); ?>
  69  
  70                  <span class="bbp-topic-started-in"><?php printf( esc_html__( 'in: %1$s', 'bbpress' ), '<a href="' . bbp_get_forum_permalink( bbp_get_topic_forum_id() ) . '">' . bbp_get_forum_title( bbp_get_topic_forum_id() ) . '</a>' ); ?></span>
  71                  <?php do_action( 'bbp_theme_after_topic_started_in' ); ?>
  72  
  73              <?php endif; ?>
  74  
  75          </p>
  76  
  77          <?php do_action( 'bbp_theme_after_topic_meta' ); ?>
  78  
  79          <?php bbp_topic_row_actions(); ?>
  80  
  81      </li>
  82  
  83      <li class="bbp-topic-voice-count"><?php bbp_topic_voice_count(); ?></li>
  84  
  85      <li class="bbp-topic-reply-count"><?php bbp_show_lead_topic() ? bbp_topic_reply_count() : bbp_topic_post_count(); ?></li>
  86  
  87      <li class="bbp-topic-freshness">
  88  
  89          <?php do_action( 'bbp_theme_before_topic_freshness_link' ); ?>
  90  
  91          <?php bbp_topic_freshness_link(); ?>
  92  
  93          <?php do_action( 'bbp_theme_after_topic_freshness_link' ); ?>
  94  
  95          <p class="bbp-topic-meta">
  96  
  97              <?php do_action( 'bbp_theme_before_topic_freshness_author' ); ?>
  98  
  99              <span class="bbp-topic-freshness-author"><?php bbp_author_link( array( 'post_id' => bbp_get_topic_last_active_id(), 'size' => 14 ) ); ?></span>
 100  
 101              <?php do_action( 'bbp_theme_after_topic_freshness_author' ); ?>
 102  
 103          </p>
 104      </li>
 105  </ul><!-- #bbp-topic-<?php bbp_topic_id(); ?> -->


Generated: Wed Jul 17 01:01:28 2019 Cross-referenced by PHPXref 0.7.1