Send HTML emails

gustav - January 20, 2008 - 14:32
Project:Mail Editor
Version:6.x-1.x-dev
Component:User interface
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active
Description

Would it be possible to extend this module so that it can handle HTML emails, possibly using the mime mail module http://drupal.org/project/mimemail?

#1

xmacinfo - July 8, 2008 - 19:15

I'd love to see Mail editor provide two fieldsets. In the first one we would create and edit the HTML message. In the second part, we could edit the plaintext version.

The result should be a multipart mail message that would be handled automatically by the mail client.

#2

litwol - July 8, 2008 - 19:43
Version:5.x-1.1» 6.x-1.x-dev
Status:active» needs work

i dont know how to do that stuff :(.

if anyone cares to contribute a patch i will gladly review and commit it. however i dont know how to do the whole multipart and headers thing necessary for proper html email template.

#3

xmacinfo - July 10, 2008 - 20:22

For a starter you can look at PHP.net.

http://ca3.php.net/manual/en/function.mail.php

Cheers.

#4

xmacinfo - July 17, 2008 - 03:04

Here is a blog post about this subject:

Multipart HTML Emails With Drupal
http://agileapproach.com/blog-entry/multipart-html-emails-with-drupal

#5

tallsimon - December 5, 2008 - 18:08

Any progress here? I love the way Subscriptions does such neat plain text digests out of the box, it would be even more amazing if it could do it in HTML. I was wanting to use the Notifications framework for email replies (mail to web) and Subscriptions for digested updates. Perhaps this is a bad idea to start with :-)

#6

roychri - August 13, 2009 - 15:20
Status:needs work» won't fix

If you want mail_edit to handle html emails, simply install the htmlmail module.
AFTER it has been installed, run the following SQL command:

UPDATE system SET weight=1 WHERE name='htmlmail';

If you installed Drupal with table prefix, be sure to adjust the table name accordingly.

Do not forget to clear the Drupal cache after that.

This will make sure that the htmlmail magic occurs AFTER the mail_edit has done it's replacing.
The problem here is that mail_edit completely disregard the body when you specify your own custom template. When htmlmail makes this email as HTML, it gets replaced by your template.

So, an alternative to what I propose is to put your full HTML inside each of your templates. I prefer the first option.

Any comments?

#7

salvis - August 21, 2009 - 07:32
Status:won't fix» active

Interesting!

If you expect comments, you shouldn't mark the issue "won't fix", because that'll take it out of sight.

 
 

Drupal is a registered trademark of Dries Buytaert.