0
标题很自我解释。我试图使用WordPress功能comments_number()
,但它总是返回零,即使有评论。我使用的代码是:comments_number()总是返回零
<?php comments_number('No Comments', '1 Comment', '% Comments'); ?>
标题很自我解释。我试图使用WordPress功能comments_number()
,但它总是返回零,即使有评论。我使用的代码是:comments_number()总是返回零
<?php comments_number('No Comments', '1 Comment', '% Comments'); ?>
该代码是正确的。
<?php comments_number('No Comments', '1 Comment', '% Comments'); ?>
是正确的方法。 可以在Codex中确认:http://codex.wordpress.org/Function_Reference/comments_number
所以你的问题,应该在你调用函数的地方......通常做的地方之一是在content.php文件中。