Exemple #1
0
/**
 * Custom the comments list.
 *
 * @since 0.0.1
 *
 * @for wp_list_comments() callback in comments.php
 *
 */
function vp_comments_list($comment, $args, $depth)
{
    $GLOBALS['comment'] = $comment;
    switch ($comment->comment_type) {
        case 'pingback':
        case 'trackback':
            break;
        default:
            ?>
	<li <?php 
            comment_class('inner');
            ?>
 id="li-comment-<?php 
            comment_ID();
            ?>
">
		<article id="comment-<?php 
            comment_ID();
            ?>
" class="comment">
			<footer class="comment-meta">
				<div class="comment-author vcard">
					<?php 
            vp_user_avatar_link(48, $comment->user_id);
            ?>
					<span class="fn"><?php 
            vp_user_profile_link($comment->user_id);
            ?>
</span>
					<?php 
            if (is_user_logged_in() && comments_open()) {
                vp_comment_reply_link();
            }
            ?>
					<?php 
            printf('<time class="comment-datetime" pubdate datetime="%1$s">%2$s</time>', get_comment_time('c'), get_comment_time('Y-n-j @ g:i a'));
            ?>

					<?php 
            edit_comment_link('edit', '<span class="edit-link">- ', '</span>');
            ?>
				</div>
			</footer>

			<div class="comment-content">
			  <?php 
            if ($comment->comment_approved == '0') {
                ?>
			  	<p class="comment-awaiting-moderation"><?php 
                _e('Your reply is awaiting moderation.', 'v2press');
                ?>
</p>
			  <?php 
            }
            ?>
			  <?php 
            comment_text();
            ?>
			</div>

		</article>
	</li>
	<?php 
            break;
    }
}
Exemple #2
0
    echo home_url();
    ?>
" title="<?php 
    _ex('Home', 'menu', 'v2press');
    ?>
"><?php 
    _ex('Home', 'menu', 'v2press');
    ?>
</a></li>
          <li<?php 
    if (is_page('member')) {
        echo ' class="current_page_item"';
    }
    ?>
><?php 
    vp_user_profile_link();
    ?>
</li>
          <li<?php 
    if (is_page('settings')) {
        echo ' class="current_page_item"';
    }
    ?>
><?php 
    vp_page_link(array('slug' => 'settings', 'text' => __('Settings', 'v2press'), 'rel' => 'nofollow'));
    ?>
</li>
          <?php 
    if (current_user_can('administrator')) {
        ?>
          <li><a href="<?php