Generating links iin mails : Action Mailer


I am using action mailer. I want to use embedded links such as :
Instead of using , i want it as My Company
which can be clicked with href to

But in the mails that go out i get the links in raw form:
Take a tour

How do i fix this? Please suggest.


Figured this out:
I just had to add this :slight_smile:
content_type “text/html”

I have a similar problem. How do I generate links in emails that work
both on localhost and on the live server?

Here’s an example email:


You have a new e-pet. Please check the page at
http://localhost:3000/pets/<%= %> for more details.


This works fine when I’m using localhost:3000 in development, but how
can I make it so the link works on both the local server and the live

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs