# bbp-core/2.0.0/templates/content-single-topic-lead.php

Forumax – AI Powered Advanced Community Forum Plugin, version 2.0.0. 135 lines.

- Page: https://pluginprobe.com/plugins/bbp-core/2.0.0/code/templates/content-single-topic-lead.php
- Raw: https://pluginprobe.com/plugins/bbp-core/2.0.0/raw/templates/content-single-topic-lead.php
- Modified: 2026-01-01T11:09:22+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/bbp-core/2.0.0/code/templates/content-single-topic-lead.php#L10-L20`.

```php
<?php

/**
 * Single Topic Lead Content Part
 *
 * @package bbPress
 * @subpackage Theme
 */

// Exit if accessed directly

defined( 'ABSPATH' ) || exit;
do_action( 'bbp_template_before_lead_topic' );
?>
<div class="main-post">
    <div class="topic-content-wrapper"> 

        <div class="forum-post-top">
            <div class="bbp-author-wrap">
                <div class="author-avatar bbp-author-link">
                    <?php 
                    echo bbp_get_topic_author_link( array(
                        'post_id' => get_the_ID(),
                        'size'    => 40,
                        'type'    => 'avatar'
                    ));
                    ?>
                </div>

                <div class="forum-post-author">
                    <div class="topic-author author-flex author-gap">
                        <?php 
                        echo bbp_get_topic_author_link( array(
                            'post_id' => get_the_ID(),
                            'type'    => 'name'
                        ));
                        ?>
                        <div class="author-badge badge <?php echo sanitize_title(forumax_get_bbp_user_role()) ?>">
                            <?php forumax_bbp_user_role_icon(); ?>
                            <span><?php echo forumax_get_bbp_user_role(); ?></span>
                        </div>
                    </div>

                    <div class="forum-author-meta meta">
                        <a href="<?php the_permalink(); ?>" title="<?php bbp_topic_post_date(); ?>">
                            <?php bbp_topic_post_date(get_the_ID(), true); ?>
                        </a>
                        <span class="dot"></span>
                        <a href="#topic-<?php bbp_topic_id(); ?>-replies" class="replies-count">
                            <?php forumax_topic_reply_count(); esc_html_e(' Replies'); ?>
                        </a>
                    </div>
                </div>
            </div>

            <div class="action-button-container">
                <?php
                if ( is_user_logged_in() ) :
                    bbp_topic_subscription_link( array(
                        'before'      => '',
                        'after'       => '',
                        'unsubscribe' => esc_html__( 'Subscribed', 'forumax' ),
                    ));
                endif;
                ?>
            </div>
        </div>

        <div class="q-title">
            <span class="question-icon" title="Question">
                <?php echo esc_html( forumax_get_opt('topic_title_prefix', 'Q:') ); ?>
            </span>
            <h1>
                <?php
                the_title();
                do_action('bbpc-resolved-topics');
                ?>
            </h1>
        </div>

        <?php do_action('bbp_theme_after_topic_author_details'); ?>

        <div class="forum-post-content">
            <div class="content editor-content">
                <?php do_action('bbp_theme_before_topic_content'); ?>
                <?php bbp_topic_content(); ?>
                <?php do_action('bbp_theme_after_topic_content'); ?>
            </div>

            <div class="forum-post-btm meta">
                <?php if ( bbp_get_topic_tag_list(get_the_ID()) ) : ?>
                    <div class="taxonomy forum-post-tags">
                        <?php
                        bbp_topic_tag_list('', array(
                            'before' => '<i class="icon_tags_alt"></i> <strong>' . esc_html__('Tagged:', 'forumax') . '</strong> <span class="tags">',
                            'after'  => '</span>'
                        ));
                        ?>
                    </div>
                <?php endif; ?>

                <div class="taxonomy forum-post-cat">
                    <?php echo get_the_post_thumbnail(bbp_get_topic_forum_id(), 'forumax_20x20'); ?>
                    <a href="<?php bbp_forum_permalink(bbp_get_topic_forum_id()); ?>">
                        <?php echo bbp_get_topic_forum_title(); ?>
                    </a>
                </div>
            </div>

            <div class="action-button-container action-btns">
                <?php if ( is_user_logged_in() ) : ?>
                    <ul class="bbp-admin-links admin-links-flex">
                        <?php
                        bbp_topic_admin_links(array(
                            'before' => '<li>',
                            'after'  => '</li>',
                            'sep'    => '</li><li>'
                        ));
                        ?>
                    </ul>
                <?php endif; ?>

                <?php
                bbp_topic_favorite_link(array(
                    'before' => '',
                ));
                ?>
            </div>
        </div>

    </div> 
</div>

<?php
do_action( 'bbp_template_after_lead_topic' );
```
