Not logged in. · Lost password · Registration disabled
Forum: Overview Questions / Fragen RSS
HTML emails not being sent as HTML
Matt Penner (Guest) #1
No profile available.
Link to this post
Subject: HTML emails not being sent as HTML
When sending email using the default English HTML template (en_US/email_template.html) the emails are being received as text.  The HTML code is plainly visible and the markup is not being rendered.  I don't know much about this but it seems like a mime type isn't being set or sent.

How do I fix this?
Thanks,
Matt Penner
Morty (Administrator) #2
User title: Author
Member since Jun 2007 · 928 posts
Group memberships: Administratoren, Mitglieder
Show profile · Link to this post
Probably you have wordpress 2.2. Normally there should be a warning on the info-page that you need this plugin: http://wordpress.org/extend/plugins/wordpress-22-mailfix/
MattPenner #3
Member since Nov 2007 · 6 posts
Group memberships: Mitglieder
Show profile · Link to this post
Thanks Morty.

I installed the MailFix plug-in but now I have more problems.

Now the following text is displayed at the top of each page on my site:
reak; } } $result = @$phpmailer->Send(); return $result; } endif; ?>

Also, if I attempt certain functions, such as logging out of my site, I get several errors similar to the following (and I don’t get logged out):
Warning: Cannot modify header information - headers already sent by (output started at /home/content/p/f/w/pfwebuser/html/wordpress/wp-content/plugins/wordpress-22-mailfix/wp_mailfix.php:101) in /home/content/p/f/w/pfwebuser/html/wordpress/wp-login.php on line 12

All the errors are the same except the line number changes.  The number of errors varies, sometimes there's just the one and sometimes there's as many as five.

I attempted to use the Test feature to send an HTML email and received the following error:
Fatal error: Call to undefined function: tolower() in /home/content/p/f/w/pfwebuser/html/wordpress/wp-content/plugins/wordpress-22-mailfix/wp_mailfix.php on line 54

So, I updated the MailFix php file and replaced tolower with strtolower.  While the Test feature now does send the HTML email with no errors, all the above problems still exist.

I'll disable the MailFix plug in for now but if you have any ideas that would be great.

Thanks!
Matt
Morty (Administrator) #4
User title: Author
Member since Jun 2007 · 928 posts
Group memberships: Administratoren, Mitglieder
Show profile · Link to this post
My Fault. The fixed _and tested_ version is attached. (wp.org should be updated soon, too.)
The author has attached one file to this post:
wp_mailfix.php | Save   2.8 kBytes, downloaded 419 times
MattPenner #5
Member since Nov 2007 · 6 posts
Group memberships: Mitglieder
Show profile · Link to this post
Thanks!  Works great.
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum