Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6322809
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T16:24:04+00:00 2026-05-24T16:24:04+00:00

I want to send html email’s with my Rails Mailer. Could be multipart/alternative or

  • 0

I want to send html email’s with my Rails Mailer.
Could be multipart/alternative or only text/html.
Problem is, when I send an email with a link, it appears well on Gmail, but not so good in Thunderbird.

The problem is, that in Thunderbird, the link is ‘not clickable’ – it’s highlighted like a link, but clicking on it does nothing.

Links on other mails (not sent from Rails Mailer) work flawlessly.

So my question is: how to properly send an html email, so it will be viewed properly?

Mailer code:

class MyMailer < ActionMailer::Base
  def mailing_delivery(email, subject)
    mail(:to => email, :subject => subject)
  end

Mail view:

# mailing_delivery.html.haml 
%p
  Thanks! Its your mailer!
%p
  = link_to "Google", "google.com"

Source of email (some parts cut-out):

Date: Thu, 18 Aug 2011 14:32:34 +0200
From: xxx
To: xxx
Message-ID: <4e4d0662bf96e_41024be957a57974@xxx.mail>
Subject: Super news!
Mime-Version: 1.0
Content-Type: text/html;
 charset=UTF-8
Content-Transfer-Encoding: 7bit
X-O2-Trust: 2, 64
X-O2-SPF: neutral

<p>
  Thanks! It's your mailer!
</p>
<p>
  <a href="google.com">Google</a>
</p>

Of course Rails 3. Thunderbird 5.0, but that’s not the issue – because somehow other mails show up good.. And I don’t think it’s app specific.

What should I do, to make this work?

Edit: I tried to change the ‘content-transfer-encoding’ header with no success, by doing mail(:to => email, :subject => subject, "Content-Transfer-Encoding" => value) or in class default "Content-Transfer-Encoding" => value with no luck.. how to change that?

Emails that works good under Thunderbird have Content-Transfer-Encoding: quoted-printable (or eventually base64) so maybe that’s the issue? How do I change it?

Edit 2: I managed to change the Content-Transfer-Encoding to quoted-printable but it’s cutting the content, like this:

Date: Thu, 18 Aug 2011 22:04:21 +0200
From: xxx
To: xxx
Message-ID: <4e4d704557839_151c4e4957c2132e@xxx.mail>
Subject: Super news!
Mime-Version: 1.0
Content-Type: text/html;
 charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-O2-Trust: 2, 63
X-O2-SPF: neutral

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://ww=
w.w3.org/TR/html4/loose.dtd">
<html>
  <body>
    <p>
      Thanks! It's your mailer!
    </p>
    <p>
      <a href=

One other thing: why is there a newline in Content-Type ? I didn’t see it in other (working good) mails. How I can get rid of it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T16:24:05+00:00Added an answer on May 24, 2026 at 4:24 pm

    Maybe it’ll work if you fix your html. So instead of just having:

    <p>
      Thanks! It's your mailer!
    </p>
    <p>
      <a href="google.com">Google</a>
    </p>
    

    try:

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html>
      <body>
        <p>
          Thanks! It's your mailer!
        </p>
        <p>
          <a href="http://google.com">Google</a>
        </p>
      </body>
    </html>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to send an html email with a link but want it
I want to send email with alternate views either plain text or html template,
I want to send a HTML email using ZEND_MAIL. The problem is that I
How can I send an HTML-formatted email with pictures using PHP? I want to
I am sending email through gmail, i want to send some html content, is
I want to send the HTML email to new registered user. I am using
I have a test.html file that I want to send via email(I am refering
I want to send html body email like below with background-image css to my
I have a complex HTML form which I want to send via email. Is
I'm trying to send out a Plain/HTML multipart email out and I'm currently using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.