Welcome to MTTags.com. Hopefully, you'll discover that this a really easy place to find information about Movable Type Template Tags. If you think we could be doing something better, please let us know! If this is your first time here, be sure to stop by the information desk, because we've got a growing todo list that might already include what you were about to suggest.

Comment// 35 Tags

MTCommentAuthor

The name of the author of the comment.

  • default

    If a name is not given, the value of this attribute will be used.

Note: This tag only works where a comment is in context, such as within a <MTComments> or <MTEntryComments> container tag.

MTCommentAuthorIdentity

A link to the author's profile within the configured TypeKey authentication system.

MTCommentAuthorLink

A linked version of the comment author name, using the comment author's URL if provided in the comment posting form. Otherwise, the comment author name is unlinked. This behavior can be altered with optional attributes:

Attributes:

  • show_email - Specifies if the comment author's email can be displayed. The default is false (0).
  • show_url - Specifies if the comment author's URL can be displayed. The default is true (1).
  • new_window - Specifies to open the link in a new window by adding "target=_blank" to the anchor tag. See example below. The default is false (0).
  • default_name - Used in the event that the commenter did not provide a value for their name.

Example code:

<$MTCommentAuthorLink new_window="1"$>

would become

<a href="http://www.sixapart.com/" target="_blank">Six Apart</a>

MTCommentBody

The body of the comment. If any text formatting has been specified it will automatically be applied.

  • convert_breaks

    Controls the application of text formatting. By default convert_breaks is 1 (true).

MTCommentDate

The email address of the comment author. The spam_protect global filter may be used.

MTCommentEmail

The email address of the comment author. The spam_protect global filter may be used.

MTCommentEntry

A container tag that creates a context to the entry associated with the comment.

Example

<MTComments lastn="10">
    <MTCommentEntry>
    <a href="<$MTEntryPermalink$>#comment-<$MTCommentID$>">

            <$MTCommentAuthor$>
    </a>

    commented on 

        <a href="<$MTEntryPermalink$>"><$MTEntryTitle$></a>

    </MTCommentEntry>
</MTComments>

MTCommentEntryID

The numeric system ID of the entry associated with the comment.

MTCommentFields

Outputs a standard comments form in HTML for all comments and authentication settings.

  • preview

    Setting this attribute to true (1) specifies that the form is being generated for a comment preview. The default is 0 (false).

MTCommentID

The numeric system ID of the comment.

  • pad

    Adds leading zeros to create a 6 character string. The default is 0 (false). This is equivalent to using the zero_pad global filter with a value of 6.

MTCommentIP

The IP (Internet Protocol) network address the comment was submitted from.

MTCommentOrderNumber

The placement of the comment in numerical order beginning at 1. This value is dependent on the sort order being used.

MTCommentPreviewAuthor


MTCommentPreviewAuthor displays the name of the current commenter during comment preview.

MTCommentPreviewAuthor


MTCommentPreviewAuthor displays the name of the current commenter during comment preview.

MTCommentPreviewBody

MTCommentPreviewBody displays the body of the current comment during comment preview.

MTCommentPreviewDate

MTCommentPreviewDate shows the date of the current comment during comment preview.

MTCommentPreviewEmail

MTCommentPreviewEmail displays the email of the current commenter during comment preview.

MTCommentPreviewIP

MTCommentPreviewIP shows the IP address of the current commenter during comment preview.

MTCommentPreviewState

Deprecated. Do not use.

MTCommentPreviewURL

MTCommentPreviewURL shows the URL of the current commenter during comment preview.

MTCommentURL

The URL of the comment author.

MTCommentURL

The URL of the comment author.

MTCommenterEmail

The email address of the commenter. The spam_protect global filter may be used.

MTCommenterIfTrusted

A conditional block which outputs its contents if the author of the comment in context is both authenticated and has a Trusted status on the current blog.

NOTE:

An `MTElse` block within this tag would only be executed if the commenter was authenticated but not Trusted. If the commenter is not authenticated, the entire block is skipped.

MTCommenterName

The name of the commenter.

MTCommenterNameThunk

Populates the commenter_name Javascript variable.

MTComments

A container tag which iterates over a list of comments on an entry or for a weblog. By default, all comments in context (e.g on an entry or in a weblog) are returned. When used in a blog context, only comments on published entries are returned.

Optional attributes
  • lastn - Display the last N comments in context where N is a positive integer. NOTE: lastn required in a weblog context.

  • sort_order - Specifies the sort order and overrides the General Settings. Recognized values are "ascend" and "descend."

  • blog_ids - This attribute allows you to aggregate comments from other blogs into your MTComments listing. Blogs are specified by their blog IDs in a comma-delimited fashion. (e.g. <MTComments blog_ids="1,12,19,37,112">). A value of all expands the context to all blogs in the installation. This feature is available only in Movable Type Enterprise.

MTComments

A container tag which iterates over a list of comments on an entry or for a weblog. By default, all comments in context (e.g on an entry or in a weblog) are returned. When used in a blog context, only comments on published entries are returned.

Optional attributes
  • lastn - Display the last N comments in context where N is a positive integer. NOTE: lastn required in a weblog context.

  • sort_order - Specifies the sort order and overrides the General Settings. Recognized values are "ascend" and "descend."

  • blog_ids - This attribute allows you to aggregate comments from other blogs into your MTComments listing. Blogs are specified by their blog IDs in a comma-delimited fashion. (e.g. <MTComments blog_ids="1,12,19,37,112">). A value of all expands the context to all blogs in the installation. This feature is available only in Movable Type Enterprise.

Related

MTCommentsFooter

The contents of this container tag will be displayed when the last comment listed by a MTComments tagset is reached.

MTCommentsHeader

The contents of this container tag will be displayed when the first comment listed by a MTComments tagset is reached.

MTFeedbackScore

The composite score of a comment or TrackBack after junk filtering.

MTIfCommenterTrusted

A conditional tag that displays its contents if the commenter in context has be marked as trusted.

What is the difference between MTCommentAuthor and MTCommenterName? what about MTCommentEmail and MTCommenterEmail?

MTIfCommentsAccepted

Conditional tag that displays its contents if commenting is enabled for the entry in context.

MTIfCommentsActive

Conditional tag that displays its contents if comments are enabled or comments exist for the entry in context.

MTIfCommentsModerated

Conditional tag that displays its contents if comment submissions are moderated before being published.