3 * The template for displaying comments
5 * The area of the page that contains both current comments
6 * and the comment form.
9 * @subpackage Twenty_Fifteen
10 * @since Twenty Fifteen 1.0
14 * If the current post is protected by a password and
15 * the visitor has not yet entered the password we will
16 * return early without loading the comments.
18 if ( post_password_required() ) {
23 <div id="comments" class="comments-area">
25 <?php if ( have_comments() ) : ?>
26 <h2 class="comments-title">
28 printf( _nx( 'One thought on “%2$s”', '%1$s thoughts on “%2$s”', get_comments_number(), 'comments title', 'twentyfifteen' ),
29 number_format_i18n( get_comments_number() ), get_the_title() );
33 <?php twentyfifteen_comment_nav(); ?>
35 <ol class="comment-list">
37 wp_list_comments( array(
43 </ol><!-- .comment-list -->
45 <?php twentyfifteen_comment_nav(); ?>
47 <?php endif; // have_comments() ?>
50 // If comments are closed and there are comments, let's leave a little note, shall we?
51 if ( ! comments_open() && get_comments_number() && post_type_supports( get_post_type(), 'comments' ) ) :
53 <p class="no-comments"><?php _e( 'Comments are closed.', 'twentyfifteen' ); ?></p>
56 <?php comment_form(); ?>
58 </div><!-- .comments-area -->