Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 78 lines (69 sloc) 3.176 kb
8249a3b @saltcod First commit.
authored
1 <?php
2 /**
3 * The template for displaying Comments.
4 *
5 * The area of the page that contains both current comments
6 * and the comment form. The actual display of comments is
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
7 * handled by a callback to victoria_park_comment() which is
8249a3b @saltcod First commit.
authored
8 * located in the functions.php file.
9 *
10 * @package WordPress
190c366 @saltcod Removed Toolbox references, changed to Victoria Park
authored
11 * @subpackage Victoria Park
12 * @since Victoria Park 0.1
8249a3b @saltcod First commit.
authored
13 */
14 ?>
15 <div id="comments">
16 <?php if ( post_password_required() ) : ?>
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
17 <p class="nopassword"><?php _e( 'This post is password protected. Enter the password to view any comments.', 'victoria_park' ); ?></p>
8249a3b @saltcod First commit.
authored
18 </div><!-- #comments -->
19 <?php
20 /* Stop the rest of comments.php from being processed,
21 * but don't kill the script entirely -- we still have
22 * to fully load the template.
23 */
24 return;
25 endif;
26 ?>
27
28 <?php // You can start editing here -- including this comment! ?>
29
30 <?php if ( have_comments() ) : ?>
31 <h2 id="comments-title">
32 <?php
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
33 printf( _n( 'One thought on &ldquo;%2$s&rdquo;', '%1$s thoughts on &ldquo;%2$s&rdquo;', get_comments_number(), 'victoria_park' ),
8249a3b @saltcod First commit.
authored
34 number_format_i18n( get_comments_number() ), '<span>' . get_the_title() . '</span>' );
35 ?>
36 </h2>
37
38 <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : // are there comments to navigate through ?>
39 <nav id="comment-nav-above">
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
40 <h1 class="assistive-text section-heading"><?php _e( 'Comment navigation', 'victoria_park' ); ?></h1>
41 <div class="nav-previous"><?php previous_comments_link( __( '&larr; Older Comments', 'victoria_park' ) ); ?></div>
42 <div class="nav-next"><?php next_comments_link( __( 'Newer Comments &rarr;', 'victoria_park' ) ); ?></div>
8249a3b @saltcod First commit.
authored
43 </nav>
44 <?php endif; // check for comment navigation ?>
45
46 <ol class="commentlist">
47 <?php
48 /* Loop through and list the comments. Tell wp_list_comments()
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
49 * to use victoria_park_comment() to format the comments.
8249a3b @saltcod First commit.
authored
50 * If you want to overload this in a child theme then you can
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
51 * define victoria_park_comment() and that will be used instead.
52 * See victoria_park_comment() in victoria_park/functions.php for more.
8249a3b @saltcod First commit.
authored
53 */
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
54 wp_list_comments( array( 'callback' => 'victoria_park_comment' ) );
8249a3b @saltcod First commit.
authored
55 ?>
56 </ol>
57
58 <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : // are there comments to navigate through ?>
59 <nav id="comment-nav-below">
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
60 <h1 class="assistive-text section-heading"><?php _e( 'Comment navigation', 'victoria_park' ); ?></h1>
61 <div class="nav-previous"><?php previous_comments_link( __( '&larr; Older Comments', 'victoria_park' ) ); ?></div>
62 <div class="nav-next"><?php next_comments_link( __( 'Newer Comments &rarr;', 'victoria_park' ) ); ?></div>
8249a3b @saltcod First commit.
authored
63 </nav>
64 <?php endif; // check for comment navigation ?>
65
66 <?php
67 /* If there are no comments and comments are closed, let's leave a little note, shall we?
68 * But we don't want the note on pages or post types that do not support comments.
69 */
70 elseif ( ! comments_open() && ! is_page() && post_type_supports( get_post_type(), 'comments' ) ) :
71 ?>
c84c7e4 @saltcod toolbox > victoria_park text replace
authored
72 <p class="nocomments"><?php _e( 'Comments are closed.', 'victoria_park' ); ?></p>
8249a3b @saltcod First commit.
authored
73 <?php endif; ?>
74
75 <?php comment_form(); ?>
76
77 </div><!-- #comments -->
Something went wrong with that request. Please try again.