Body: <p>In my experience of working with CiviCRM, which goes back further than I care to remember, it has often been tricky to identify which message template is being when invoices/receipts/confirmation messages get sent out. Template names are sometimes different from those used in the current documentation (especially where an older site has been upgraded many times), and there is nothing  - at least nothing obvious I can spot - in the resulting emails/messages that help to identify the template.</p>
  <p>Judging by some of the questions asked here I'm not alone in this confusion. As a proposed solution, what about including suitable comments in the source template, such that they appear in the source of the resulting communication but not in rendered messages, which identify the template being used?</p>
  <p>On the face of it this sounds like  pretty straightforward thing to implement, if it would work.</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-07-07T20:27:12.877Z
Comments.Text: This seems like an interesting proposal but I don't think it really suits the format of StackExchange. It might be better to propose it in GitLab instead: lab.civicrm.org/dev/core/-/issues
Comments.UserDisplayName: William Mortada
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-11-22T13:17:42.483Z
Comments.Text: This is old but I think go for it. I think a header like `X-civicrm-mstgpl-id: 123` would work better than including unrenderable (unreadable? what about plain text? what about screen readers?) content
Comments.UserDisplayName: artfulrobot
Tags: <message-templates><system-workflow-messages>
Title: How to identify which message template is being used?
ThreadText: # How to identify which message template is being used?
  
  (Asked by: username_0 on 2020-07-03)
  
  In my experience of working with CiviCRM, which goes back further than I care to remember, it has often been tricky to identify which message template is being when invoices/receipts/confirmation messages get sent out. Template names are sometimes different from those used in the current documentation (especially where an older site has been upgraded many times), and there is nothing - at least nothing obvious I can spot - in the resulting emails/messages that help to identify the template.
  
  Judging by some of the questions asked here I'm not alone in this confusion. As a proposed solution, what about including suitable comments in the source template, such that they appear in the source of the resulting communication but not in rendered messages, which identify the template being used?
  
  On the face of it this sounds like pretty straightforward thing to implement, if it would work.
  
  **Tags:** message-templates, system-workflow-messages
  
  > **Comments:**
  > **username_1**: This seems like an interesting proposal but I don't think it really suits the format of StackExchange. It might be better to propose it in GitLab instead: lab.civicrm.org/dev/core/-/issues  
  > **username_2**: This is old but I think go for it. I think a header like `X-civicrm-mstgpl-id: 123` would work better than including unrenderable (unreadable? what about plain text? what about screen readers?) content  
  
  ---
  
  ## 0 answers
  
  