Answers.Body: <p>A.1 </p>
  
  <ul>
  <li><p>in my 4.7.x test the dropdown arrow to the right of  works to show me the tokens, but does not result in them being inserted. In my 4.6 test this did work (which suggests a JIRA issue might be needed for 4.7 but can't test on dmaster as the drupal permission has not been assigned)</p></li>
  <li><p>in my 4.6.x test the dropdown arrow to the right of  works to show me the tokens, and does result in them being inserted.</p></li>
  </ul>
  
  <p>A.2 address type tokens are {contact.country} and {contact.street_address}</p>
  
  <p>A.3 I don't see any membership based tokens listed. I believe we - Fuzion = did an Extension that can help with this - try <a href="https://github.com/eileenmcnaughton/nz.co.fuzion.civitoken" rel="nofollow noreferrer">this one</a></p>
  
  <p>A.4 I don't know and am not sure what you are referencing.</p>
  
  <p>A.5 In the 4.6.x it shows as full width and has a handle in bottom-left corner to drag it bigger. In my 4.7.x test it only shows as half-width but still has the handle. Guess if you are missing the handle you may need to check for js errors or something else like a WP theme issue??</p>
  
  <p>Hope that helps you a bit.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-04T01:17:13.820Z
Answers.Text: NB my testing was on Drupal but this should all be agnostic
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-04T02:06:52.940Z
Answers.Text: A.4.  {$cancelled} appears in the default template. I too would like to know its purpose.
Answers.UserDisplayName: Codedogs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-04T02:10:14.133Z
Answers.Text: A.5. My version has no such edges. It is as it appears in the picture above. I do remember seeing them in a previous version, though it may have been on a different page.
Answers.UserDisplayName: Codedogs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-04T03:04:57.720Z
Answers.Text: $cancelled might be to do with the transaction in that case (guessing)
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-06T14:53:46.970Z
Answers.Text: A.5 $cancelled remains false when the status of the membership is cancelled.
Answers.UserDisplayName: Codedogs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-04T01:10:09.357Z
Answers.LastActivityDate: 2017-02-04T03:05:46.313Z
Answers.LastEditDate: 2017-02-04T03:05:46.313Z
Answers.UserDisplayName: petednz - fuzion
Answers.Body: <p><strong>Question 1.</strong> Should one be able to click on a token and put it into a template? In my case, it shows  Tokens.</p>
  
  <p><strong>Answer:</strong> Yes. Seems to be disabled in 4.7.15</p>
  
  <p><strong>Question 2.</strong> What is the token syntax if you were able to click on one in the token dropdown? I need the address, so I assumed {address.street_name}, but this does not work nor does {$address.street_name}.</p>
  
  <p><strong>Answer:</strong> </p>
  
  <pre><code>{capture assign=address_line_2} {contact.supplemental_address_1} {/capture}
  {capture assign=address_line_3} {contact.supplemental_address_2} {/capture}
  {capture assign=address_suffix} {contact.postal_code_suffix} {/capture}
  {capture assign=line_2_size} {$address_line_1|count_characters:false} {/capture}
  {capture assign=line_3_size} {$address_line_2|count_characters:false} {/capture}
  {capture assign=suffix_size} {$address_suffix|count_characters:false} {/capture}
  
  {capture assign=casem_member_address}
          {contact.street_address}&lt;br/&gt;
      {if $line_2_size GT 0}
          {contact.supplemental_address_1}&lt;br/&gt;
      {/if}
      {if $line_3_size GT 0}
          {contact.supplemental_address_2}&lt;br/&gt;
      {/if}
          {contact.city}, {contact.state_province}&lt;br/&gt;
          {contact.country}&lt;br/&gt;
          {contact.postal_code}
      {if $suffix_size GT 0}
          -{contact.postal_code_suffix}
      {/if}
  {/capture}
  </code></pre>
  
  <p>The supplemental address lines and the postal code suffix are null by default and causes a fatal error in Smarty. (The spinning symbol) However, the above code gets around it. </p>
  
  <p><strong>Question 3.</strong> Why does {$membershipStatus} show the previous status instead of the current one? Is there another token for the current status?</p>
  
  <p><strong>Answer:</strong>  $contribution_status_id does show the correct value for renewals</p>
  
  <p><strong>Question 4.</strong> {$cancelled} does not follow the Membership status of cancelled. What does it represent?</p>
  
  <p>civicrm\civicrm\CRM\Member\Form\Membership.php
  lines 1593 to 1603</p>
  
  <pre><code>$cancelled = TRUE;
  if ($membership-&gt;end_date) {
    //display end date w/ status message.
    $endDate = $membership-&gt;end_date;
  
    if (!in_array($membership-&gt;status_id, array(
      // CRM-15475
      array_search('Cancelled', CRM_Member_PseudoConstant::membershipStatus(NULL, " name = 'Cancelled' ", 'name', FALSE, TRUE)),
      array_search('Expired', CRM_Member_PseudoConstant::membershipStatus()),
    ))
    ) {
      $cancelled = FALSE;
    }
  }
  // suppress form values in template.
  $this-&gt;assign('cancelled', $cancelled);
  </code></pre>
  
  <p>Likely the answer has to do with the fix for CRM-15475. </p>
  
  <p><strong>Question 5.</strong> Does anyone else feel that the text-area provided for editing is a little too small? A Message Preview option would be so helpful. </p>
  
  <p><strong>Answer:</strong> Alas in the WordPress version, only certain pages are using the chkeditor boxes which can be expanded by the user. I guess they have not propogated these boxes into the Message Edit pages. </p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-06T21:48:30.840Z
Answers.LastActivityDate: 2017-02-06T21:48:30.840Z
Answers.UserDisplayName: Codedogs
Answers.Body: <p>Q1 was a regression introduced in 4.7. It gets fixed by applying <a href="https://github.com/civicrm/civicrm-core/pull/10149" rel="nofollow noreferrer">https://github.com/civicrm/civicrm-core/pull/10149</a> change.</p>
  
  <p>JIRA filed here - <a href="https://issues.civicrm.org/jira/browse/CRM-20418" rel="nofollow noreferrer">https://issues.civicrm.org/jira/browse/CRM-20418</a></p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-04-12T10:00:05.573Z
Answers.LastActivityDate: 2017-04-12T10:00:05.573Z
Answers.UserDisplayName: jitendra - fuzion
Body: <p>CiviCRM 4.7.15 for WordPress</p>
  
  <p><strong>Mailings\Message templates\System Message Templates</strong> editing an offline Membership template</p>
  
  <p>This template gets emailed whenever selects Edit or Renew under Memberships for a contact. Edit also allows one to override the status to cancelled, expired, on hold, and 5 other states. </p>
  
  <p><a href="https://i.sstatic.net/2hY9g.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/2hY9g.png" alt="HTML section of template"></a></p>
  
  <p><strong>Question 1.</strong> Should one be able to click on a token and put it into a template? In my case, it shows <code>&lt;/&gt;</code> Tokens.</p>
  
  <p><strong>Question 2.</strong> What is the token syntax if you were able to click on one in the token dropdown? I need the address, so I assumed {address.street_name}, but this does not work nor does {$address.street_name}.</p>
  
  <p><strong>Question 3.</strong> Why does {$membershipStatus} show the previous status instead of the current one? Is there another token for the current status?</p>
  
  <p><strong>Question 4.</strong> {$cancelled} does not follow the Membership status of cancelled. What does it represent?</p>
  
  <p><strong>Question 5.</strong> Does anyone else feel that the text-area provided for editing is a little too small? A Message Preview option would be so helpful. </p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-04T00:34:37.460Z
Comments.Text: {debug} gives a nice list, but not of the tokens from the dropdown
Comments.UserDisplayName: Codedogs
Tags: <wordpress><tokens><message-templates>
Title: Need Token Help for System Message Template
ThreadText: # Need Token Help for System Message Template
  
  (Asked by: username_0 on 2017-02-04)
  
  CiviCRM 4.7.15 for WordPress
  
  **Mailings\Message templates\System Message Templates** editing an offline Membership template
  
  This template gets emailed whenever selects Edit or Renew under Memberships for a contact. Edit also allows one to override the status to cancelled, expired, on hold, and 5 other states.
  
  [![HTML section of template](https://i.sstatic.net/2hY9g.png)](https://i.sstatic.net/2hY9g.png)
  
  **Question 1.** Should one be able to click on a token and put it into a template? In my case, it shows  Tokens.
  
  **Question 2.** What is the token syntax if you were able to click on one in the token dropdown? I need the address, so I assumed {address.street\_name}, but this does not work nor does {$address.street\_name}.
  
  **Question 3.** Why does {$membershipStatus} show the previous status instead of the current one? Is there another token for the current status?
  
  **Question 4.** {$cancelled} does not follow the Membership status of cancelled. What does it represent?
  
  **Question 5.** Does anyone else feel that the text-area provided for editing is a little too small? A Message Preview option would be so helpful.
  
  **Tags:** wordpress, tokens, message-templates
  
  > **Comments:**
  > **username_0**: {debug} gives a nice list, but not of the tokens from the dropdown  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_1 on 2017-02-04. Score: 1
  
  A.1
  
  * in my 4.7.x test the dropdown arrow to the right of works to show me the tokens, but does not result in them being inserted. In my 4.6 test this did work (which suggests a JIRA issue might be needed for 4.7 but can't test on dmaster as the drupal permission has not been assigned)
  * in my 4.6.x test the dropdown arrow to the right of works to show me the tokens, and does result in them being inserted.
  
  A.2 address type tokens are {contact.country} and {contact.street\_address}
  
  A.3 I don't see any membership based tokens listed. I believe we - Fuzion = did an Extension that can help with this - try [this one](https://github.com/eileenmcnaughton/nz.co.fuzion.civitoken)
  
  A.4 I don't know and am not sure what you are referencing.
  
  A.5 In the 4.6.x it shows as full width and has a handle in bottom-left corner to drag it bigger. In my 4.7.x test it only shows as half-width but still has the handle. Guess if you are missing the handle you may need to check for js errors or something else like a WP theme issue??
  
  Hope that helps you a bit.
  
  > **Comments:**
  > **username_1**: NB my testing was on Drupal but this should all be agnostic  
  > **username_0**: A.4.  {$cancelled} appears in the default template. I too would like to know its purpose.  
  > **username_0**: A.5. My version has no such edges. It is as it appears in the picture above. I do remember seeing them in a previous version, though it may have been on a different page.  
  > **username_1**: $cancelled might be to do with the transaction in that case (guessing)  
  > **username_0**: A.5 $cancelled remains false when the status of the membership is cancelled.  
  
  ---
  
  ### Answer by username_0 on 2017-02-06. Score: 1
  
  Question 1. Should one be able to click on a token and put it into a template? In my case, it shows  Tokens.
  Answer: Yes. Seems to be disabled in 4.7.15
  Question 2. What is the token syntax if you were able to click on one in the token dropdown? I need the address, so I assumed {address.street_name}, but this does not work nor does {$address.street_name}.
  Answer: 
  {capture assign=address_line_2} {contact.supplemental_address_1} {/capture}
  {capture assign=address_line_3} {contact.supplemental_address_2} {/capture}
  {capture assign=address_suffix} {contact.postal_code_suffix} {/capture}
  {capture assign=line_2_size} {$address_line_1|count_characters:false} {/capture}
  {capture assign=line_3_size} {$address_line_2|count_characters:false} {/capture}
  {capture assign=suffix_size} {$address_suffix|count_characters:false} {/capture}
  
  {capture assign=casem_member_address}
          {contact.street_address}
      {if $line_2_size GT 0}
          {contact.supplemental_address_1}
      {/if}
      {if $line_3_size GT 0}
          {contact.supplemental_address_2}
      {/if}
          {contact.city}, {contact.state_province}
          {contact.country}
          {contact.postal_code}
      {if $suffix_size GT 0}
          -{contact.postal_code_suffix}
      {/if}
  {/capture}
  
  The supplemental address lines and the postal code suffix are null by default and causes a fatal error in Smarty. (The spinning symbol) However, the above code gets around it. 
  Question 3. Why does {$membershipStatus} show the previous status instead of the current one? Is there another token for the current status?
  Answer:  $contribution_status_id does show the correct value for renewals
  Question 4. {$cancelled} does not follow the Membership status of cancelled. What does it represent?
  civicrm\civicrm\CRM\Member\Form\Membership.php
  lines 1593 to 1603
  $cancelled = TRUE;
  if ($membership->end_date) {
    //display end date w/ status message.
    $endDate = $membership->end_date;
  
    if (!in_array($membership->status_id, array(
      // CRM-15475
      array_search('Cancelled', CRM_Member_PseudoConstant::membershipStatus(NULL, " name = 'Cancelled' ", 'name', FALSE, TRUE)),
      array_search('Expired', CRM_Member_PseudoConstant::membershipStatus()),
    ))
    ) {
      $cancelled = FALSE;
    }
  }
  // suppress form values in template.
  $this->assign('cancelled', $cancelled);
  
  Likely the answer has to do with the fix for CRM-15475. 
  Question 5. Does anyone else feel that the text-area provided for editing is a little too small? A Message Preview option would be so helpful. 
  Answer: Alas in the WordPress version, only certain pages are using the chkeditor boxes which can be expanded by the user. I guess they have not propogated these boxes into the Message Edit pages.
  
  
  ---
  
  ### Answer by username_2 on 2017-04-12. Score: 1
  
  Q1 was a regression introduced in 4.7. It gets fixed by applying <https://github.com/civicrm/civicrm-core/pull/10149> change.
  
  JIRA filed here - <https://issues.civicrm.org/jira/browse/CRM-20418>
  
  
  ---
  
  