Skip to content
  1. Extras
  2. Tickets
  3. Snippets
  4. TicketComments

TicketComments

Outputs comments and a form to comment on a resource.

Can be used with any MODX document. The snippet must be called uncached.

Snippet call parameters

NameDefaultDescription
&allowGuest0Allow unauthenticated users to comment?
&allowGuestEdit1Allow guests to edit their own comments?
&allowGuestEmails0Send email notifications about replies to guests?
&autoPublish1Automatically publish all new comments without moderation.
&autoPublishGuest1Automatically publish all new comments from guests without moderation.
&depth0Integer: maximum depth of the comment thread.
&enableCaptcha1Enable spam protection for unauthenticated users?
&fastMode1If enabled, only raw DB values are passed to the result chunk; all unprocessed MODX tags are stripped.
&formBefore0Show the comment form above the comments. Default: no.
&toPlaceholderDo not output the result; put it in the placeholder toPlaceholder.
&separatePlaceholder0If 1, output the form and comments to toPlaceholder_form and toPlaceholder_thread.
&gravatarIconmmFallback image when the user avatar is not found.
&gravatarSize24Size of the loaded avatar.
&gravatarUrlhttp://www.gravatar.com/avatar/URL for loading avatars.
&maxCaptcha10Maximum value for the spam-protection code.
&minCaptcha1Minimum value for the spam-protection code.
&threadComment thread name. Default: resource-[[*id]].
&tplCommentAuthtpl.Tickets.comment.one.authChunk for a comment shown to a logged-in user.
&tplCommentDeletedtpl.Tickets.comment.one.deletedChunk for a deleted comment.
&tplCommentEmailBcctpl.Tickets.comment.email.bccChunk for notifying site admins of a new comment.
&tplCommentEmailOwnertpl.Tickets.comment.email.ownerChunk for notifying the ticket owner of a new comment.
&tplCommentEmailReplytpl.Tickets.comment.email.replyChunk for notifying a user that their comment received a reply.
&tplCommentEmailSubscriptiontpl.Tickets.comment.email.subscriptionChunk for notifying a subscribed user of a new comment in the thread.
&tplCommentFormtpl.Tickets.comment.formChunk for the new-comment form.
&tplCommentFormGuesttpl.Tickets.comment.form.guestChunk for the new-comment form for guests.
&tplCommentGuesttpl.Tickets.comment.one.guestChunk for a comment shown to guests.
&tplCommentstpl.Tickets.comment.wrapperWrapper chunk for all comments on the page.
&tplLoginToCommenttpl.Tickets.comment.loginChunk prompting the user to log in to comment.

Examples

  • Standard snippet call
modx
[[!TicketComments?]]
  • Snippet call with comments allowed for unauthenticated users
modx
[[!TicketComments? &allowGuest=`1`]]