| 1 |
<?php |
| 2 |
// Exit if accessed directly |
| 3 |
if( ! defined( 'ABSPATH' ) ) exit; |
| 4 |
|
| 5 |
function wpforo_thread_forum_template( $topicid ) { |
| 6 |
$thread = wpforo_thread( $topicid ); |
| 7 |
if( empty( $thread ) ) return; |
| 8 |
?> |
| 9 |
<div class="wpf-thread <?php wpforo_unread( $topicid, 'topic' ); ?>"> |
| 10 |
<div class="wpf-thread-body"> |
| 11 |
<div class="wpf-thread-box wpf-thread-status"> |
| 12 |
<div class="wpf-thread-statuses" <?php echo $thread['wrap']; ?>><?php echo $thread['icons_html']; ?></div> |
| 13 |
</div> |
| 14 |
<div class="wpf-thread-box wpf-thread-title"> |
| 15 |
<span class="wpf-thread-status-mobile"><?php wpforo_topic_icon( $thread ); ?> </span> |
| 16 |
<?php wpforo_topic_title( $thread, $thread['url'], '{p}{au}{tc}{/a}{n}{v}', true, '', wpforo_setting( 'forums', 'layout_threaded_intro_topics_length' ) ) ?> |
| 17 |
<?php wpforo_tags( $thread, true, 'text' ) ?> |
| 18 |
<div class="wpf-thread-forum-mobile"> |
| 19 |
<i class="<?php echo $thread['forum']['icon'] ?>" style="color: <?php echo $thread['forum']['color'] ?>"></i> |
| 20 |
<?php $forum_description = (wpfval($thread['forum'], 'description')) ? 'wpf-tooltip="' . esc_attr(strip_tags((string) $thread['forum']['description'])) . '" wpf-tooltip-size="long"' : ''; ?> |
| 21 |
<a href="<?php echo esc_url((string) $thread['forum']['url']); ?>" <?php echo $forum_description ?>> |
| 22 |
<?php echo esc_attr( $thread['forum']['title'] ) ?> |
| 23 |
</a> |
| 24 |
</div> |
| 25 |
</div> |
| 26 |
<div class="wpf-thread-box wpf-thread-forum"> |
| 27 |
<span class="wpf-circle wpf-m" wpf-tooltip="<?php echo esc_attr( $thread['forum']['title'] ) ?>" wpf-tooltip-position="left" wpf-tooltip-size="long" style="border:1px dashed <?php echo $thread['forum']['color'] ?>"><i class="<?php echo $thread['forum']['icon'] ?>" style="color: <?php echo $thread['forum']['color'] ?>"></i></span> |
| 28 |
</div> |
| 29 |
<div class="wpf-thread-box wpf-thread-posts"> |
| 30 |
<?php echo wpforo_print_number( ( intval( $thread['posts'] ) - 1 ) ) ?> |
| 31 |
</div> |
| 32 |
<div class="wpf-thread-box wpf-thread-views"> |
| 33 |
<?php echo wpforo_print_number( $thread['views'] ) ?> |
| 34 |
</div> |
| 35 |
<div class="wpf-thread-box wpf-thread-users"> |
| 36 |
<?php echo $thread['users_html']; ?> |
| 37 |
<div class="wpf-thread-date-mobile"><?php echo $thread['last_post_date'] ?></div> |
| 38 |
</div> |
| 39 |
<div class="wpf-thread-box wpf-thread-date"> |
| 40 |
<?php echo $thread['last_post_date'] ?> |
| 41 |
</div> |
| 42 |
</div> |
| 43 |
</div> |
| 44 |
<?php |
| 45 |
} |
| 46 |
|