WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My wordpress makes use of custom post templates. I'm now trying to create a custom comments template as well.

I noticed that the comments template is called via this function <?php comments_template( '', true ); ?>

I checked in my functions.php and comments.php but don't see the function being declared anywhere. Can someone please advise on how to go about introducing a custom comments template?

share|improve this question
@Chip Bennet, thanks for the heads up. Reading through that page, I notice that to set up an alternative comments template, i'd have to use this <?php comments_template( '/short-comments.php' ); ?> so am I right in assuming that I can start off by copy pasting the code from comments.php into short-comments.php and then work my way through from there? – Sledge81 Oct 27 '11 at 13:31
You can do it that way, but why? What are you trying to accomplish? – Chip Bennett Oct 27 '11 at 15:06
up vote 1 down vote accepted

The comments_template() template tag sets up the commenting variables and functions, and includes the comments.php template-part file. So, to create a custom comments template, use comments.php.

From there, you will need to get comfortable with the arguments, filters, and callbacks for wp_list_comments(), which is used to output the comment list, and comment_form(), which is used to output the comment-reply form.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.