| 1 |
<?php |
| 2 |
// Exit if accessed directly |
| 3 |
if( ! defined( 'ABSPATH' ) ) exit; |
| 4 |
?> |
| 5 |
|
| 6 |
<div class="wpfl-2"> |
| 7 |
|
| 8 |
<div class="wpforo-post-head"> |
| 9 |
<div class="wpf-left"> |
| 10 |
<a href="<?php echo esc_url( (string) wpforo_post( $topic['last_post'], 'url' ) ); ?>" class="wpfcl-2"><i class="far fa-caret-square-down wpfsx wpfcl-3"></i> <span class="wpfcl-3"><?php wpforo_phrase( 'Last Post' ); ?></span></a> |
| 11 |
<?php do_action( 'wpforo_topic_head_left', $forum, $topic ) ?> |
| 12 |
</div> |
| 13 |
<div class="wpf-right"> |
| 14 |
<?php do_action( 'wpforo_topic_head_right', $forum, $topic ) ?> |
| 15 |
<?php wpforo_post_buttons( 'icon-text', 'tools', $forum ); ?> |
| 16 |
<?php wpforo_feed_link(); ?> |
| 17 |
</div> |
| 18 |
<div class="wpf-clear"></div> |
| 19 |
</div> |
| 20 |
<?php wpforo_moderation_tools(); ?> |
| 21 |
|
| 22 |
<?php foreach( $posts as $key => $post ) : ?> |
| 23 |
|
| 24 |
<?php $member = wpforo_member( $post ); |
| 25 |
$wpf_is_anon = function_exists('wpforo_is_anonymous_mask_member') ? wpforo_is_anonymous_mask_member($member) : false; |
| 26 |
$post_url = wpforo_post( $post['postid'], 'url' ); ?> |
| 27 |
<div id="post-<?php echo wpforo_bigintval( $post['postid'] ) ?>" data-postid="<?php echo wpforo_bigintval( $post['postid'] ) ?>" data-userid="<?php echo wpforo_bigintval( $member['userid'] ) ?>" data-mention="<?php echo esc_attr( ( wpforo_setting( 'profiles', 'mention_nicknames' ) ? $member['user_nicename'] : '' ) ) ?>" data-isowner="<?php echo esc_attr( (int) (bool) wpforo_is_owner( $member['userid'] ) ) ?>" |
| 28 |
class="post-wrap wpfn-<?php echo( $key + 1 ); ?><?php if( $post['is_first_post'] ) echo ' wpfp-first' ?>"> |
| 29 |
<?php wpforo_share_toggle( $post_url, $post['body'] ); ?> |
| 30 |
<div class="wpforo-post wpfcl-1"> |
| 31 |
<div class="wpf-left"> |
| 32 |
<?php if( WPF()->usergroup->can( 'va' ) && wpforo_setting( 'profiles', 'avatars' ) ): ?> |
| 33 |
<div class="author-avatar"><?php echo wpforo_user_avatar( $member, 110 ) ?></div> |
| 34 |
<?php endif; ?> |
| 35 |
<div class="author-data"> |
| 36 |
<div class="author-name"><span><?php WPF()->member->show_online_indicator( $member['userid'] ) ?></span> <?php wpforo_member_link( $member ); ?></div> |
| 37 |
<?php if( empty($wpf_is_anon) ) { wpforo_member_nicename( $member, '@' ); } ?> |
| 38 |
<?php if( (int) wpfval( $member, 'userid' ) ) : ?> |
| 39 |
<div class="wpf-member-profile-buttons"> |
| 40 |
<?php WPF()->tpl->member_buttons( $member ) ?> |
| 41 |
</div> |
| 42 |
<div class="author-title"> |
| 43 |
<?php wpforo_member_title( $member ) ?> |
| 44 |
</div> |
| 45 |
<?php wpforo_member_badge( $member ) ?> |
| 46 |
<?php endif; ?> |
| 47 |
</div> |
| 48 |
<div class="wpf-clear"></div> |
| 49 |
</div><!-- left --> |
| 50 |
<div class="wpf-right"> |
| 51 |
<div class="wpforo-post-content-top"> |
| 52 |
<?php do_action( 'wpforo_post_content_top_left', $post ) ?> |
| 53 |
<div class="wpf-post-actions"> |
| 54 |
<?php if( $post['is_first_post'] ) { |
| 55 |
$buttons = [ 'solved', 'sticky', 'private', 'close', 'report', 'delete', 'link' ]; |
| 56 |
} else { |
| 57 |
$buttons = [ 'report', 'delete', 'link' ]; |
| 58 |
} |
| 59 |
wpforo_post_buttons( 'icon-text', $buttons, $forum, $topic, $post ); |
| 60 |
?> |
| 61 |
</div> |
| 62 |
<?php wpforo_share_toggle( $post_url, $post['body'], 'top' ); ?> |
| 63 |
</div> |
| 64 |
<div class="wpforo-post-content"> |
| 65 |
<?php wpforo_content( $post ); ?> |
| 66 |
<?php wpforo_post_edited( $post ); ?> |
| 67 |
<?php do_action( 'wpforo_tpl_post_loop_after_content', $post, $member ) ?> |
| 68 |
<?php if( wpforo_setting( 'profiles', 'signature' ) ): ?> |
| 69 |
<?php if( $member['signature'] ): ?> |
| 70 |
<div class="wpforo-post-signature"><?php wpforo_signature( $member ) ?></div><?php endif; ?> |
| 71 |
<?php endif; ?> |
| 72 |
<div class="wpf-post-button-actions"> |
| 73 |
<?php |
| 74 |
$buttons = [ 'custom-bottom', 'reply', 'quote', 'approved', 'edit' ]; |
| 75 |
wpforo_post_buttons( 'icon-text', $buttons, $forum, $topic, $post ); |
| 76 |
?> |
| 77 |
<?php if( $post['status'] ): ?> |
| 78 |
<span class="wpf-mod-message"><i class="fas fa-exclamation-circle" aria-hidden="true"></i> <?php wpforo_phrase( 'Awaiting moderation' ) ?></span> |
| 79 |
<?php endif; ?> |
| 80 |
</div> |
| 81 |
<?php do_action( 'wpforo_post_content_end', $post, $topic, $forum, 2 ); ?> |
| 82 |
</div> |
| 83 |
<div class="wpforo-post-content-bottom"> |
| 84 |
<div class="cbleft wpfcl-0"> |
| 85 |
<?php wpforo_topic_starter( $topic, $post ) ?> |
| 86 |
<?php wpforo_phrase( 'Posted' ) ?> : <?php wpforo_date( $post['created'], 'd/m/Y g:i a' ) ?> |
| 87 |
<?php do_action( 'wpforo_post_bottom_end', $post, $topic, $forum, 2 ); ?> |
| 88 |
</div> |
| 89 |
<div class="wpf-clear"></div> |
| 90 |
</div> |
| 91 |
</div><!-- right --> |
| 92 |
<div class="wpf-clear"></div> |
| 93 |
</div><!-- wpforo-post --> |
| 94 |
</div><!-- post-wrap --> |
| 95 |
|
| 96 |
<?php if( $post['is_first_post'] ): ?> |
| 97 |
<div class="wpforo-topic-meta"> |
| 98 |
<?php wpforo_tags( $topic ); ?> |
| 99 |
</div> |
| 100 |
<?php endif; ?> |
| 101 |
|
| 102 |
<?php do_action( 'wpforo_loop_hook', $key ) ?> |
| 103 |
|
| 104 |
<?php endforeach; ?> |
| 105 |
</div><!-- wpfl-2 --> |
| 106 |
|