Example #1
0
function get_comment_nav()
{
    ?>

	<?php 
    if (get_comment_pages_count() > 1) {
        ?>
	<div class="comments-nav">
		<div class="prev">
			<?php 
        previous_comments_link(__('Prev Comments', 'rb'));
        ?>
		</div>
		<div class="next">
			<?php 
        next_comments_link(__('Next Comments', 'rb'));
        ?>
		</div>
	</div>
	<?php 
    }
    ?>

<?php 
}
Example #2
0
/**
 * Comments Nav
 * @since 0.1.0
 */
function tamatebako_comments_nav()
{
    if (get_option('page_comments') && 1 < get_comment_pages_count()) {
        // Check for paged comments.
        ?>

	<div class="comments-nav">

		<?php 
        previous_comments_link('<span class="prev-comments"><span class="screen-reader-text">' . tamatebako_string('previous_comment') . '</span></span>');
        ?>

		<span class="page-numbers"><?php 
        printf('%1$s / %2$s', get_query_var('cpage') ? absint(get_query_var('cpage')) : 1, get_comment_pages_count());
        ?>
</span>

		<?php 
        next_comments_link('<span class="next-comments"><span class="screen-reader-text">' . tamatebako_string('next_comment') . '</span></span>');
        ?>

	</div><!-- .comments-nav -->

<?php 
    }
    // End check for paged comments.
}
 function thb_comments_navigation()
 {
     global $post;
     if (get_comment_pages_count() > 1 && get_option('page_comments')) {
         previous_comments_link(__('Older comments', 'thb_text_domain'));
         next_comments_link(__('Newer comments', 'thb_text_domain'));
     }
 }
Example #4
0
/**
 * Echo Genesis default comment structure.
 *
 * @since 1.1.2
 *
 * @uses genesis_get_option()
 *
 * @global stdClass $post Post object
 * @global WP_Query $wp_query
 * @return null Returns early if on a page with Genesis pages comments off, or a post and Genesis posts comments off.
 */
function genesis_do_comments()
{
    global $post, $wp_query;
    /** Bail if comments are off for this post type */
    if (is_page() && !genesis_get_option('comments_pages') || is_single() && !genesis_get_option('comments_posts')) {
        return;
    }
    if (have_comments() && !empty($wp_query->comments_by_type['comment'])) {
        ?>
		<div id="comments">
			<?php 
        echo apply_filters('genesis_title_comments', __('<h3>Comments</h3>', 'genesis'));
        ?>
			<ol class="comment-list">
				<?php 
        do_action('genesis_list_comments');
        ?>
			</ol>
			<div class="navigation">
				<div class="alignleft"><?php 
        previous_comments_link();
        ?>
</div>
				<div class="alignright"><?php 
        next_comments_link();
        ?>
</div>
			</div>
		</div><!--end #comments-->
		<?php 
    } else {
        ?>
		<div id="comments">
			<?php 
        /** Comments are open, but there are no comments */
        if ('open' == $post->comment_status) {
            echo apply_filters('genesis_no_comments_text', '');
        } else {
            /** Comments are closed */
            echo apply_filters('genesis_comments_closed_text', '');
        }
        ?>
		</div><!--end #comments-->
		<?php 
    }
}
Example #5
0
/**
 * Output comment structure.
 *
 * @uses calibrefx_get_option()
 *
 */
function calibrefx_do_comments()
{
    global $post, $wp_query;
    /** Bail if comments are off for this post type */
    if (is_page() && !calibrefx_get_option('comments_pages') || is_single() && !calibrefx_get_option('comments_posts')) {
        return;
    }
    if (have_comments() && !empty($wp_query->comments_by_type['comment'])) {
        ?>
        <div id="comments">
                <?php 
        echo apply_filters('calibrefx_title_comments', __('<h3>Comments</h3>', 'calibrefx'));
        ?>
                <ol class="comment-list">
                        <?php 
        do_action('calibrefx_list_comments');
        ?>
                </ol>
                <div class="comment-navigation">
                    <ul class="pager">
                        <li class="previous"><?php 
        previous_comments_link();
        ?>
</li>
                        <li class="next"><?php 
        next_comments_link();
        ?>
</li>
                    </ul>
                </div>
        </div><!--end #comments-->
        <?php 
    } else {
        echo '<div id="comments" class="no-comments">';
        if ('open' == $post->comment_status) {
            echo apply_filters('calibrefx_no_comments_text', '');
        } else {
            echo apply_filters('calibrefx_comments_closed_text', '');
        }
        echo '</div><!--end #comments-->';
    }
}
Example #6
0
/**
 * Comments nav
 */
function scaffolder_comment_nav()
{
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
        <nav id="comment-nav-above" class="navigation comment-navigation" role="navigation">
            <h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'scaffold');
        ?>
</h1>
            <div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'scaffold'));
        ?>
</div>
            <div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'scaffold'));
        ?>
</div>
        </nav>
    <?php 
    }
}
    /**
     * Display navigation to next/previous comments pages when applicable
     *
     * @author	Konstantin Obenland
     * @since	1.5.0 - 19.05.2012
     *
     * @return	void
     */
    function the_bootstrap_comment_nav()
    {
        if (get_comment_pages_count() > 1 and get_option('page_comments')) {
            // are there comments to navigate through
            ?>
	<nav class="comment-nav well">
		<h1 class="assistive-text"><?php 
            _e('Comment navigation', 'the-bootstrap');
            ?>
</h1>
		<div class="nav-previous alignleft"><?php 
            next_comments_link(__('&larr; Newer Comments', 'the-bootstrap'));
            ?>
</div>
		<div class="nav-next alignright"><?php 
            previous_comments_link(__('Older Comments &rarr;', 'the-bootstrap'));
            ?>
</div>
	</nav>
	<?php 
        }
        // check for comment navigation
    }
<?php

// DISPLAY COMMENTS IF COMMENTS ARE OPENED
if (comments_open()) {
    echo '<div class="comments">', '<h2>';
    _e('Comentários', 'wikiwp');
    // alterado
    echo '</h2>';
    if (have_comments()) {
        // this is displayed if there are comments
        echo '<h3>';
        _e('Este post tem', 'wikiwp');
        echo '&nbsp;';
        comments_number(__('0 comentários', 'wikiwp'), __('um comentário', 'wikiwp'), __('% comentários', 'wikiwp'));
        echo '</h3>', '<ul class="commentlist">';
        wp_list_comments();
        echo '</ul>', '<div class="comment-nav">', '<div class="alignleft">';
        previous_comments_link();
        echo '</div>', '<div class="alignright">';
        next_comments_link();
        echo '</div>', '</div>';
    } else {
        // this is displayed if there are no comments so far
        _e('Nenhum comentário!', 'wikiwp');
    }
    // load comment form
    comment_form();
    echo '</div>';
    // end of .content
}
Example #9
0
		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
		<nav id="comment-nav-below" class="comment-navigation navigation" role="navigation">
			<h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'responsive-mobile');
        ?>
</h1>
			<div class="nav-previous previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'responsive-mobile'));
        ?>
</div>
			<div class="nav-next next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'responsive-mobile'));
        ?>
</div>
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // check for comment navigation
    ?>

	<?php 
}
// have_comments()
?>

	<?php 
// If comments are closed and there are comments, let's leave a little note, shall we?
Example #10
0
		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
		<nav role="navigation" id="comment-nav-below" class="site-navigation comment-navigation">
			<h1 class="assistive-text"><?php 
        _e('Comment navigation', 'abelard');
        ?>
</h1>
			<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'abelard'));
        ?>
</div>
			<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'abelard'));
        ?>
</div>
		</nav>
		<?php 
    }
    // check for comment navigation
    ?>

	<?php 
}
// have_comments()
?>

	<?php 
// If comments are closed and there are comments, let's leave a little note, shall we?
Example #11
0
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // Are there comments to navigate through?
        ?>
		<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
			<h2 class="screen-reader-text"><?php 
        esc_html_e('Comment navigation', 'bizwebsky');
        ?>
</h2>
			<div class="nav-links">

				<div class="nav-previous"><?php 
        previous_comments_link(esc_html__('Older Comments', 'bizwebsky'));
        ?>
</div>
				<div class="nav-next"><?php 
        next_comments_link(esc_html__('Newer Comments', 'bizwebsky'));
        ?>
</div>

			</div><!-- .nav-links -->
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // Check for comment navigation.
    ?>

	<?php 
}
// Check for have_comments().
?>
Example #12
0
	</ul>

	<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
	<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
		<h1 class="sr-only"><?php 
        _e('Comment navigation', 'tt');
        ?>
</h1>
		<div class="nav-previous"><?php 
        previous_comments_link(__('&laquo; Older Comments', 'tt'));
        ?>
</div>
		<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &raquo;', 'tt'));
        ?>
</div>
		<div class="clearfix"></div>
	</nav>
	<?php 
    }
    // Check for comment navigation.
    ?>

	<?php 
    if (!comments_open()) {
        ?>
	<p class="no-comments"><?php 
        _e('Comments are closed.', 'tt');
        ?>
Example #13
0
		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
		<nav id="comment-nav-below" class="comment-navigation" role="navigation">
			<h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'avenue');
        ?>
</h1>
			<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'avenue'));
        ?>
</div>
			<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'avenue'));
        ?>
</div>
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // check for comment navigation
    ?>

	<?php 
}
// have_comments()
?>

	<?php 
// If comments are closed and there are comments, let's leave a little note, shall we?
Example #14
0
			<?php 
    wp_list_comments('avatar_size=80');
    ?>
		</ol>

		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // Are there comments to navigate through?
        ?>
		<div class="navigation">
			<div class="nav-previous"><?php 
        previous_comments_link(__('<span class="meta-nav">&larr;</span> Older Comments', 'wppb_lang'));
        ?>
</div>
			<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments <span class="meta-nav">&rarr;</span>', 'wppb_lang'));
        ?>
</div>
		</div><!-- .navigation -->
		<?php 
    }
    // check for comment navigation
    ?>

	<?php 
} else {
    // or, if we don't have comments:
    /* If there are no comments and comments are closed,
     * let's leave a little note, shall we?
     */
    if (!comments_open()) {
Example #15
0
			<?php 
        if (get_comment_pages_count() > 1 && get_option('page_comments')) {
            // are there comments to navigate through
            ?>
			<nav id="comment-nav-below" class="navigation" role="navigation">
				<h1 class="assistive-text section-heading"><?php 
            _e('Comment navigation', 'boss');
            ?>
</h1>
				<div class="nav-previous"><?php 
            previous_comments_link(__('&larr; Older Comments', 'boss'));
            ?>
</div>
				<div class="nav-next"><?php 
            next_comments_link(__('Newer Comments &rarr;', 'boss'));
            ?>
</div>
			</nav>
			<?php 
        }
        // check for comment navigation
        ?>

			<?php 
        /* If there are no comments and comments are closed, let's leave a note.
         * But we only want the note on posts and pages that had comments in the first place.
         */
        if (!comments_open() && get_comments_number()) {
            ?>
			<p class="nocomments"><?php 
		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
		<nav id="comment-nav-below" class="comment-navigation" role="navigation">
			<h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'wen-corporate');
        ?>
</h1>
			<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'wen-corporate'));
        ?>
</div>
			<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'wen-corporate'));
        ?>
</div>
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // check for comment navigation
    ?>

	<?php 
}
// have_comments()
?>

	<?php 
// If comments are closed and there are comments, let's leave a little note, shall we?
Example #17
0
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // Are there comments to navigate through?
        ?>
		<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
			<h2 class="screen-reader-text"><?php 
        esc_html_e('Comment navigation', 'konnichi-an');
        ?>
</h2>
			<div class="nav-links">

				<div class="nav-previous"><?php 
        previous_comments_link(esc_html__('Older Comments', 'konnichi-an'));
        ?>
</div>
				<div class="nav-next"><?php 
        next_comments_link(esc_html__('Newer Comments', 'konnichi-an'));
        ?>
</div>

			</div><!-- .nav-links -->
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // Check for comment navigation.
    ?>

	<?php 
}
// Check for have_comments().
?>
Example #18
0
	</ol>

	<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
	<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
		<h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'ib-educator');
        ?>
</h1>
		<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'ib-educator'));
        ?>
</div>
		<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'ib-educator'));
        ?>
</div>
	</nav>
	<?php 
    }
    ?>

	<?php 
    if (!comments_open()) {
        ?>
	<p class="no-comments"><?php 
        _e('Comments are closed.', 'ib-educator');
        ?>
</p>
	<?php 
Example #19
0
    /* are there comments to navigate through */
    ?>
        <?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
        <nav id="comment-nav-below" class="navigation" role="navigation">

            <div class="nav-previous">
                <?php 
        previous_comments_link(__('&larr; Older Comments', 'teaberry'));
        ?>
            </div>

            <div class="nav-next">
                <?php 
        next_comments_link(__('Newer Comments &rarr;', 'teaberry'));
        ?>
            </div>

        </nav>
        <?php 
    }
    ?>

        <?php 
    /* comments are closed */
    ?>
        <?php 
    if (!comments_open() && get_comments_number()) {
        ?>
        <h2 class="comments-closed-title">
Example #20
0
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // Are there comments to navigate through?
        ?>
		<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
			<h2 class="screen-reader-text"><?php 
        esc_html_e('Comment navigation', 'shannon-group');
        ?>
</h2>
			<div class="nav-links">

				<div class="nav-previous"><?php 
        previous_comments_link(esc_html__('Older Comments', 'shannon-group'));
        ?>
</div>
				<div class="nav-next"><?php 
        next_comments_link(esc_html__('Newer Comments', 'shannon-group'));
        ?>
</div>

			</div><!-- .nav-links -->
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // Check for comment navigation.
    ?>

	<?php 
}
// Check for have_comments().
?>
Example #21
0
		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
		<nav id="comment-nav-below" class="navigation" role="navigation">
			<h1 class="assistive-text section-heading"><?php 
        _e('Comment navigation', 'tokopress');
        ?>
</h1>
			<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'tokopress'));
        ?>
</div>
			<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'tokopress'));
        ?>
</div>
		</nav>
		<?php 
    }
    // check for comment navigation
    ?>

		<?php 
    /* If there are no comments and comments are closed, let's leave a note.
     * But we only want the note on posts and pages that had comments in the first place.
     */
    if (!comments_open() && get_comments_number()) {
        ?>
			<p class="nocomments"><?php 
Example #22
0
		<?php 
    // Are there comments to navigate through?
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
		<nav class="navigation comment-navigation row clr" role="navigation">
			<h4 class="assistive-text section-heading heading"><span><?php 
        _e('Comment navigation', 'att');
        ?>
</span></h4>
			<div class="nav-previous span_12 col clr-margin"><?php 
        previous_comments_link(__('&larr; Older Comments', 'att'));
        ?>
</div>
			<div class="nav-next span_12 col"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'att'));
        ?>
</div>
		</nav>
		<?php 
    }
    // Check for comment navigation
    ?>

		<?php 
    if (!comments_open() && get_comments_number()) {
        ?>
		<p class="no-comments"><?php 
        _e('Comments are closed.', 'att');
        ?>
</p>
Example #23
0
		<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
		<nav id="comment-nav-below" class="comment-navigation" role="navigation">
			<h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'rara-clean');
        ?>
</h1>
			<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'rara-clean'));
        ?>
</div>
			<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'rara-clean'));
        ?>
</div>
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // check for comment navigation
    ?>

	<?php 
}
// have_comments()
?>

	<?php 
// If comments are closed and there are comments, let's leave a little note, shall we?
Example #24
0
                <ul class="pager">
                    <?php 
        if (get_previous_comments_link()) {
            ?>
                        <li class="previous"><?php 
            previous_comments_link(__('&larr; Older comments', 'sage'));
            ?>
</li>
                    <?php 
        }
        ?>
                    <?php 
        if (get_next_comments_link()) {
            ?>
                        <li class="next"><?php 
            next_comments_link(__('Newer comments &rarr;', 'sage'));
            ?>
</li>
                    <?php 
        }
        ?>
                </ul>
            </nav>
        <?php 
    }
    ?>
    <?php 
}
// have_comments()
?>
Example #25
0
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // Are there comments to navigate through?
        ?>
		<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
			<h2 class="screen-reader-text"><?php 
        esc_html_e('Comment navigation', 'bftp');
        ?>
</h2>
			<div class="nav-links">

				<div class="nav-previous"><?php 
        previous_comments_link(esc_html__('Older Comments', 'bftp'));
        ?>
</div>
				<div class="nav-next"><?php 
        next_comments_link(esc_html__('Newer Comments', 'bftp'));
        ?>
</div>

			</div><!-- .nav-links -->
		</nav><!-- #comment-nav-below -->
		<?php 
    }
    // Check for comment navigation.
}
// Check for have_comments().
// If comments are closed and there are comments, let's leave a little note, shall we?
if (!comments_open() && get_comments_number() && post_type_supports(get_post_type(), 'comments')) {
    ?>

		<p class="no-comments"><?php 
Example #26
0
    ?>
</ul><ul><?php 
    wp_list_comments(array('avatar_size' => 60, 'short_ping' => true, 'callback' => array($Flavour_Vanilj, '__getComments'), 'type' => 'comment'));
    ?>
</ul>

	<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
	<nav id="comment-nav-below" class="navigation comment-navigation" role="navigation">
		<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'vanilj'));
        ?>
</div>
		<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'vanilj'));
        ?>
</div>
	</nav>
	<?php 
    }
    ?>

	<?php 
}
?>

	<?php 
if (!comments_open()) {
    ?>
		<p class="no-comments"><?php 
        echo '<h2>' . __('Reviews', 'woocommerce') . '</h2>';
    }
    $title_reply = '';
    if (have_comments()) {
        echo '<ol class="commentlist">';
        wp_list_comments(array('callback' => 'woocommerce_comments'));
        echo '</ol>';
        if (get_comment_pages_count() > 1 && get_option('page_comments')) {
            ?>
			<div class="navigation">
				<div class="nav-previous"><?php 
            previous_comments_link(__('<span class="meta-nav">&larr;</span> Previous', 'woocommerce'));
            ?>
</div>
				<div class="nav-next"><?php 
            next_comments_link(__('Next <span class="meta-nav">&rarr;</span>', 'woocommerce'));
            ?>
</div>
			</div>
		<?php 
        }
        //echo '<p class="add_review"><a href="#review_form" class="show_review_form button"><span>'.__('Add Review', 'woocommerce').'</span></a></p>';
        echo '<hr>';
        $title_reply = __('Add a review', 'woocommerce');
    } else {
        $title_reply = __('Be the first to review', 'woocommerce') . ' &ldquo;' . $post->post_title . '&rdquo;';
        echo '<p>' . __('There are no reviews yet, would you like to <a href="#review_form" class="inline show_review_form">submit yours</a>?', 'woocommerce') . '</p>';
    }
    $commenter = wp_get_current_commenter();
    echo '</div><div id="review_form_wrapper"><div id="review_form" class="form">';
    $comment_form = array('title_reply' => $title_reply, 'comment_notes_before' => '', 'comment_notes_after' => '', 'fields' => array('author' => '<div class="formField">' . '<label for="author">' . __('Name', 'woocommerce') . '<span class="required">*</span>' . '</label> ' . '<input id="author" name="author" type="text" class="textField" value="' . esc_attr($commenter['comment_author']) . '" size="30" /></p>' . '<div class="clear"></div>' . '</div>', 'email' => '<div class="formField">' . '<label for="email">' . __('Email', 'woocommerce') . '<span class="required">*</span>' . '</label> ' . '<input id="email" name="email" type="text" class="textField" value="' . esc_attr($commenter['comment_author_email']) . '" size="30" aria-required="true" /></p>' . '<div class="clear"></div>' . '</div>'), 'label_submit' => __('Submit Review', 'woocommerce'), 'logged_in_as' => '', 'comment_field' => '');
			<?php 
    wp_list_comments(array('style' => 'ol', 'short_ping' => true, 'avatar_size' => 48));
    ?>
		</ol><!-- .comment-list -->

		<?php 
    // Are there comments to navigate through?
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        ?>
			<nav class="navigation comment-navigation" role="navigation">
				<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'deference'));
        ?>
</div>
				<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'deference'));
        ?>
</div>
			</nav><!-- .comment-navigation -->
		<?php 
    }
    // Check for comment navigation
    ?>

		<?php 
    if (!comments_open() && get_comments_number()) {
        ?>
			<p class="no-comments"><?php 
        _e('Comments are closed.', 'deference');
        ?>
</p>
Example #29
0
	<?php 
    if (get_comment_pages_count() > 1 && get_option('page_comments')) {
        // are there comments to navigate through
        ?>
			<nav id="comment-nav-below" class="comment-navigation" role="navigation">
				<h1 class="screen-reader-text"><?php 
        _e('Comment navigation', 'sennzaversion3');
        ?>
</h1>
				<div class="nav-previous"><?php 
        previous_comments_link(__('&larr; Older Comments', 'sennzaversion3'));
        ?>
</div>
				<div class="nav-next"><?php 
        next_comments_link(__('Newer Comments &rarr;', 'sennzaversion3'));
        ?>
</div>
			</nav><!-- #comment-nav-below -->
			<?php 
    }
    // check for comment navigation
    ?>

	<?php 
}
// have_comments()
?>

	<?php 
// If comments are closed and there are comments, let's leave a little note, shall we?
    public function sfw_comment_form_header()
    {
        global $comment;
        // Comment form header start
        if (post_password_required()) {
            ?>
			<p class="sfw-no-password">This post is password protected. Enter the password to view comments.</p>
			<?php 
            return;
        }
        // if comments are open
        if (have_comments()) {
            ?>
			<h2 id="sfw-comments-title">
			<?php 
            printf(_n('One comment on &ldquo;%2$s&rdquo;', '%1$s comments on &ldquo;%2$s&rdquo;', get_comments_number()), number_format_i18n(get_comments_number()), '<span>' . get_the_title() . '</span>');
            ?>
			</h2>
			<?php 
            // Generates the list of comments
            ?>
			<ol class="sfw-commentlist">
			<?php 
            wp_list_comments(array('callback' => array($this, 'SFWlist_comments')));
            ?>
			</ol>
			<?php 
            // if comments are paginated (broken into pages) provides link to next and previous page
            if (get_comment_pages_count() > 1 && get_option('page_comments')) {
                // are there comments to navigate through
                ?>
				<div id="sfw-comment-nav-above">
					<div class="sfw-nav-previous">
					<?php 
                previous_comments_link('&larr; Older Comments');
                ?>
					</div>
					<div class="sfw-nav-next">
					<?php 
                next_comments_link('Newer Comments &rarr;');
                ?>
					</div>
				</div>
				<?php 
            }
        } elseif (!comments_open() && !is_page() && post_type_supports(get_post_type(), 'comments')) {
            ?>
			<p class="sfw-nocomments">Comments are closed.</p>
			<?php 
        }
        // Comment form header end
        // Call the comment form template
        $this->sfw_comment_form();
    }