bbp_reply_class(); ?> > <td class="bbp-reply-author"> <?php bbp_reply_author_link(); ?> <?php if (is_super_admin()) { ?> <div class="bbp-reply-ip"><?php bbp_author_ip(bbp_get_reply_id()); ?> </div> <?php } ?> </td> <td class="bbp-reply-content"> <?php bbp_reply_content(); ?>
?> <?php bbp_topic_author_link(array('sep' => '<br />', 'show_role' => true)); ?> <?php if (bbp_is_user_keymaster()) { ?> <?php do_action('bbp_theme_before_topic_author_admin_details'); ?> <div class="bbp-topic-ip"><?php bbp_author_ip(bbp_get_topic_id()); ?> </div> <?php do_action('bbp_theme_after_topic_author_admin_details'); ?> <?php } ?> <?php do_action('bbp_theme_after_topic_author_details'); ?>
/** * @covers ::bbp_author_ip * @covers ::bbp_get_author_ip */ public function test_bbp_get_author_ip() { $t = $this->factory->topic->create(); $author_ip = '<span class="bbp-author-ip">(127.0.0.1)</span>'; // String. $this->assertSame($author_ip, bbp_get_author_ip($t)); // Output. $this->expectOutputString($author_ip); bbp_author_ip($t); }
/** * Add post date, author post count and author ip to the author element. */ public function add_author_post_date_count_ip() { ?> <div class="bbp-reply-post-date"><?php bbp_reply_post_date(bbp_get_reply_id()); ?> </div> <div class="bbps-post-count"><?php printf(__('Post count: %s', 'Avada'), bbp_get_user_reply_count_raw(bbp_get_reply_author_id()) + bbp_get_user_topic_count_raw(bbp_get_reply_author_id())); ?> </div> <?php if (bbp_is_user_keymaster()) { ?> <?php do_action('bbp_theme_before_topic_author_admin_details'); ?> <div class="bbp-reply-ip fusion-reply-id"><?php bbp_author_ip(bbp_get_topic_id()); ?> </div> <?php do_action('bbp_theme_after_topic_author_admin_details'); ?> <?php } }
/** * Output the contents of the `bbp_topic_reply_author` column * * @since 2.6.0 bbPress (r5886) */ public function column_bbp_topic_reply_author($item = '') { bbp_reply_author_avatar($item->ID, 50); bbp_reply_author_display_name($item->ID); echo '<br>'; bbp_reply_author_email($item->ID); echo '<br>'; bbp_author_ip(array('post_id' => $item->ID)); }