Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Configure the Mail Sender

Excerpt

The mail sender configuration refers the mail templates directory and templates localization.

...

  1. Engine searches for fr_FR/mytemplate.tpl in the templates directory. If found, it is returned (we It is displayed if it is found. We suppose the locale is French/France, and not Canadian French for instance Canadian French). The directory searched there is the language ISO 2 letter code of and the language plus the ISO 2 letter country code.
  2. If it is not found, the engine continues to searches next for  for fr/mytemplate.tpl. In other words, it drops the country code from the directory. If it is found, it will be returnedis displayed.
  3. If it is still not found, the engine searches for mytemplate.tpl. This means that there's no localization available for this template. Again, if found, it is returned. 
  4. If mytemplate.tpl is not found, the search results in error and the string may be interpreted as suchlike this.

With this algorithm cleared, let's see where the second parameter ('Mail language on sender/receiver') kicks in. If set on the sender, the locale is very easily determined - it is the sender's language - and the engine will send a single email, with the template resolved as above. If on the other hand, that parameter is set on the receiver, the engine will perform performs additional steps:

  1. Group Groups recipients from TO, CC, BCC fields based on language.
  2. Resolve Resolves each template based on that language, as shown.
  3. Send Sends mails to each group thus determined, to keep the language consistent.

Therefore, when setting the ' receiver ' to determine the language, the engine may send multiple mails, one in each language; of course, maximum number of mails sent is equal with the length of unique recipient list. While this is a very useful feature, this also impacts the performance and the memory used (if . If you're using queues).

SIL Template Language

Within the templates, any standard or custom field defined in the issue that called the routine can be referenced using the notation $field$. In fact, we expanded this notation and we created, started with version 4.0, a meta language named STL (not from Standard, but SIL). This language allows embedding snippets of SIL within the template (so . So you can output multiple rows in a html table, for instance). You can read more about STL in its dedicated chapter.

 

Tip
titleTip

You can create, edit, delete email templates using the built-in editor.

...