O'Reilly logo

WordPress 2.8 Themes Cookbook by Lee Jordan, Nick Ohrn

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Displaying comments on a post

After users leave comments on your posts, you'll obviously want to display them. The most frequent use case for displaying comments is to list all of the comments on a single post, and there is a template tag that does this quickly and easily. In this recipe, we'll take a look at the template tags used to display comments and where you would use them.

How to do it...

First, you'll need to decide where you want to display your comments. The most obvious place to use comment template tags would be in a custom comments template. Alternatively, you could just list comments directly on a post without concern for the other things that a comments template provides (appropriate inputs and more).

Here we'll use the default ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required