I studied the project.module to see how I should send mails to my mailinglist subscribers. I found the _mail hook. So on, evberything goes okay.
At the end of the project_mail there is the following line:

$trans = get_html_translation_table(HTML_ENTITIES);

Is this required to send the mails in ASC II? So when I bypass this, people 'can' recieve mails in HTML-format?

The meaning is to let users choose if they want to recieve HTML mails or in ASC II format, using radiobuttons. The HTML mail will be using the default Drupal theme as a template for the mail.

i stand always open for feedback and suggestions..

Thanx,

Stefan Nagtegaal.
Stefan@Frontaal-Online.com
http://www.frontaal-online.com/drupal/

Comments

Kjartan’s picture

$trans = get_html_translation_table(HTML_ENTITIES);

What this code does is translate HTML entities back into its plain text equivalents. Basically transforms &lt; into a <

This has nothing to do with the mail being HTML or plain text. It just makes a plain text mail more logical to read. To send HTML mail you will have to check out a PHP mime class or library. There should be one in PEAR and there are others around as well. Others can provide more info on that I am sure.

--
Kjartan

Stefan Nagtegaal’s picture

Thanks for your usefull help Natrak!