If comments

On this page:



The if_comments tag is a conditional tag and always used as an opening and closing pair, like this…

    …conditional statement…

The tag will execute the contained statements if there are one or more comments associated with a particular article. Should be used in an ‘article’ type form.


This tag has no attributes.


Example 1: Number of comments associated with an article

        <txp:comments_count />
<txp:else />
    <p>No comments.</p>

Displays the number of comments written against the current article, otherwise display text to indicate there are no comments.

Other tags used: comments_count, else.

See something wrong in this document? Outdated info, a broken link, faulty code example, or whatever? Please open an issue and we’ll investigate.