Ejemplo n.º 1
0
?>
>
		<div class="ap-card-gr"></div>
	</div>
	<div class="ap-card-content">
	    <div class="ap-avatar">
			<a href="<?php 
ap_user_the_link();
?>
">
				<?php 
ap_user_the_avatar(80);
?>
			</a>
	        <?php 
ap_follow_button(ap_user_get_the_ID());
?>
	    </div>
	    <div class="no-overflow">
	        <a href="<?php 
ap_user_the_link();
?>
" class="ap-card-name"><?php 
ap_user_the_display_name();
?>
</a>
	        <div class="ap-card-reputation"><span><?php 
ap_user_the_reputation();
?>
</span><?php 
_e('Reputation', 'ap');
Ejemplo n.º 2
0
/**
 * Return array of user name, to be used in display name user field
 * @param  integer $user_id
 * @return array
 * @since 2.1
 */
function ap_user_get_display_name_option($user_id = false)
{
    $user_id = ap_parameter_empty(@$user_id, @ap_user_get_the_ID());
    $user = ap_user_get_the_meta(false, $user_id);
    $public_display = array();
    if (!empty($user['nickname'])) {
        $public_display[$user['nickname']] = $user['nickname'];
    }
    if (!empty($user['user_login'])) {
        $public_display[$user['user_login']] = $user['user_login'];
    }
    if (!empty($user['first_name'])) {
        $public_display[$user['first_name']] = $user['first_name'];
    }
    if (!empty($user['last_name'])) {
        $public_display[$user['last_name']] = $user['last_name'];
    }
    if (!empty($user['first_name']) && !empty($user['last_name'])) {
        $public_display[$user['first_name'] . ' ' . $user['last_name']] = $user['first_name'] . ' ' . $user['last_name'];
        $public_display[$user['last_name'] . ' ' . $user['first_name']] = $user['last_name'] . ' ' . $user['first_name'];
    }
    return $public_display;
}
Ejemplo n.º 3
0
?>
</a>
	        <div class="ap-card-reputation"><span><?php 
ap_user_the_reputation();
?>
</span><?php 
_e('Reputation', 'anspress-question-answer');
?>
</div>
	        <div class="ap-card-stats">
	            <span><?php 
echo ap_icon('answer', true);
printf(__('%d answers, %d selected', 'anspress-question-answer'), ap_user_get_the_meta('__total_answers'), ap_user_get_the_meta('__best_answers'));
?>
</span>
	            <span><?php 
echo ap_icon('question', true);
printf(__('%d questions, %d solved', 'anspress-question-answer'), ap_user_get_the_meta('__total_questions'), ap_user_get_the_meta('__solved_answers'));
?>
</span>
	            <span><i class="apicon-comment-discussion"></i> <?php 
printf(__('%d Followers, %d following', 'anspress-question-answer'), ap_user_get_the_meta('__total_followers'), ap_user_get_the_meta('__total_following'));
?>
</span>
	        </div>
	        <?php 
do_action('ap_hover_card_after_status', ap_user_get_the_ID());
?>
	    </div>
	</div>
</div>