/ Published in: PHP
Count commetns and return value into the post
Expand |
Embed | Plain Text
<h1><?php $commentscount = get_comments_number(); if($commentscount == 1): $commenttext = 'comment'; endif; if($commentscount > 1 || $commentscount == 0): $commenttext = 'comments'; endif; ?></h1>
You need to login to post a comment.
