aboutsummaryrefslogblamecommitdiffstats
path: root/help/C/mail-composer-message-templates.page
blob: 90a120279c828ce7baf596e649d1b19490feafd5 (plain) (tree)
1
2
3
4
5
6
7
8
9







                                                                                      
                                                                              
                       

                                                  

                       
                                                                                                                                             










                                                                                                                                       
                                                                                        



























                                                                                                                
                              








































                                                                                                                                                                                                                                                                                                                                                    











                                                                                                                                                                                                                                                                                                                                                                                                                                          
       
<page xmlns="http://projectmallard.org/1.0/" xmlns:its="http://www.w3.org/2005/11/its"
type="topic" id="mail-composer-message-templates">

  <info>
 <desc>Message templates to reuse in the composer.</desc>

 <link type="guide" xref="index#mail-composing-advanced" />

 <revision pkgversion="3.5.2" version="0.2" date="2012-06-09" status="draft"/>
 <credit type="author">
   <name its:translate="no">Andre Klapper</name>
   <email its:translate="no">ak-47@gmx.net</email>
 </credit>
 <credit type="author">
   <name its:translate="no">Novell, Inc</name> <!-- Content partially from http://library.gnome.org/users/evolution/2.32/b1dlaazl.html.en -->
 </credit>
 <license>
   <p>Creative Commons Share Alike 3.0</p>
 </license> 

  </info>

<title>Message Templates</title>
<p>A message template is a standard message that you can use at any time to send mail with the same pattern.</p>
<p>To enable the Message Template Plugin, click <guiseq><gui>Edit</gui><gui>Plugins</gui></guiseq> and enable <gui>Templates</gui>.</p>

<!-- TODO:POST-3-4: Split this into subpages maybe, and turn this into a guide page! -->

<section id="create">
<title>Creating a Message Template from an existing Message</title>
<steps>
  <item><p>Select the message.</p></item>
  <item><p>Right-click the message and choose <gui>Move to folder</gui> or <gui>Copy to folder</gui>.</p></item>
  <item><p>Select the <gui>Templates</gui> folder under <gui>On This Computer</gui>.</p></item>
</steps>
<p>You can also edit an existing message and save it as a template:</p>
<steps>
  <item><p>Open the message and click <gui>Reply</gui>.</p></item>
  <item><p>Edit the message body or the addresses according to your requirements.</p></item>
  <item><p>Select <guiseq><gui>File</gui><gui>Save as Template</gui></guiseq>.</p></item>
 </steps>
</section>

<section id="save">
 <title>Saving a New Message as a Template</title>
 <steps>
  <item>
<p>Click <gui>New</gui> and enter in the composer window what you need for the template.</p>
  </item>
  <item>
<p>Select <guiseq><gui>File</gui><gui>Save as Template</gui></guiseq>.</p>
  </item>
 </steps>
</section>

<section id="reply-templates">
 <title>Using a Message Template as a Reply</title>
 <steps>
  <item>
<p>Right-click the message you are replying to, then click <gui>Templates</gui>.</p>
<p>This option lists all the message templates in the <gui>Templates</gui> folder.</p>
  </item>
  <item>
<p>Select the message template of your choice. Make changes if required in the email composer window that will open.</p>
  </item>
  <item>
<p>Click <gui>Send</gui>.</p>
<p>When you select a message template for replying, the subject of the reply is preserved.</p>
  </item>
 </steps>
</section>

<section id="configure">    
<title>Configuring Message Templates</title>
<steps>
<item><p>Select <guiseq><gui>Edit</gui><gui>Plugins</gui></guiseq>.</p></item>
<item><p>Click <gui>Templates</gui>.</p></item>
<item><p>Click the <gui>Configuration</gui> tab.</p></item>
<item><p>You can add, edit or remove the key-value pairs. You can specify any number of key-value pairs.</p></item>
</steps>
 <p>In any template, the occurrence of every $key is replaced by the value it has in the configuration. For example, if you set the key to Manager and the value to Harry, any occurrence of $Manager is replaced by Harry in the message.</p>
 <p>Assume that you have 1000 message templates with your current manager's name in them. When the current manager is replaced by a new one, it is not easy for you to manually replace the manager's name in all the 1000 messages. If the messages have a $Manager key value, you can reset the value in the Configuration tab of this plugin.</p>
 <p>By default, the entire environment variables are used as a key-value pair. An occurrence of $env_variable is replaced by the value it carries. For example, an occurrence of $PATH in your template is replaced by its value when the template is used.</p>
 <p>The replacement process uses the following order of precedence:</p>
 <steps>
  <item>
<p>$key is replaced by the value set for it in the Configuration tab of the Templates plugin.</p>
  </item>
  <item>
<p>If the key is not found, it is then replaced with the value of its environment variable.</p>
  </item>
  <item>
<p>If key is neither a configuration option nor an environment variable, no changes are made.</p>
  </item>
 </steps>
</section>

<section id="reply-variables">
<!-- as per https://bugzilla.gnome.org/show_bug.cgi?id=641845 - available since 3.2-->
<title>Reusing message elements when replying</title>
<p>Templates can contain more than just the predefined set of <link xref="#configure">key-value pairs</link>. You can also get any message header values from the email that you are applying the template on, plus the complete message body.</p>

<!-- TRANSLATORS: Do NOT translate "$ORIG[subject]" and "$ORIG[body]" in this sentence. -->
<p its:locNote="TO TRANSLATORS: Do NOT translate $ORIG[subject] and $ORIG[body] in this sentence!">In order to do this, use the format <code>$ORIG[header_name]</code> and replace the variable <code>header_name</code> by the actual header. For example, if you would like to insert the subject line of the message that you reply to, use <code>$ORIG[subject]</code>. To insert the complete body, use <code>$ORIG[body]</code>.</p>

<p>If no replacement for a variable is found, the variable is not removed (except for <code>$ORIG[body]</code>) but left in place so that you see that something went wrong. This could happen when trying to use headers that are not necessarily always available in the original message (for example <code>$ORIG[reply-to]</code>).</p>

</section>

</page>