Wordpress : always display comments with articles

2019-09-03 03:43发布

问题:

When displaying all articles of a specific month (given through the urls like this : ?m=200906&order=ASC, I would like to display, following each article, all comments regarding this article.

In the article.php of the default theme (the one I'm using), I tried to add the following line :

<?php comments_template(); ?>

before the line

<?php endwhile; ?>

(as I've seen it in single.php) but it doesn't work and I don't really now what I could try next.

回答1:

Try:

<?php $withcomments = "1"; comments_template(); ?>

From Include Tags « WordPress Codex



标签: wordpress