I still do not have a blog up so I will post here. May Google record
this so that others can find my answer and save themselves a couple
hours of debugging…
If you use the default encoding for multipart mime mail, ActionMailer or
TMail or something messes up your HTML tags and inserts a “3D” string
between every attribute="" so that you get tags looking like this:
You may never notice because your email program will render it anyway
but it has deleterious effects on your delivery and spam ranking as this
is not valid HTML.
I traced the code a bit hoping to make a fix but eventually, in the
course of testing, found a workaround.
The workaround is to explicitly specify multipart messages per the
instructions in the API for ActionMailer::Base and then Base64 encode
the HTML portion of your email. (Implicit multipart and
Quoted-printable for html multipart are broken)
part "text/plain" do |p|
p.body = render_message('marketing_email.text.plain.rhtml', @body)
part "text/html" do |p|
p.body = render_message('my_important_email.text.html.rhtml',
p.transfer_encoding = "base64" # VERY IMPORTANT
Hope this helps somebody.