OVERVIEW
~~~~~~~~
Show what is this message template thing and how does it work?
When the software was being redesigned the idea of using a template
engine (like Smarty, http://smarty.php.net) was considered but in the
end was turned down because it would probably just add extra work to
setup. Instead, a very simple system for displaying messages via a
template was designed. Whenever a message is about to be displayed
the template is loaded up and variable substitution occurs.
THE VARIABLES
~~~~~~~~~~~~~
:
The way the headers are displayed is in a loop. If you look at the
default template below you will notice that only one table row has
been defined. When the template is being parsed everything in between
the tags is displayed for each header.
In each loop is replaced with the name of the next
header and is replaced with the value of the next
header.
This is replaced with the body of the message (which has been decoded
following RFC2045 specifications).
And that's it!
DEFAULT TEMPLATE
~~~~~~~~~~~~~~~~