This project is archived and is in readonly mode.

#4421 ✓committed
Sailorxyz

Rails 3 beta3: mail_to displays incorrectly i.e. mail_to not returning html_safe string

Reported by Sailorxyz | April 16th, 2010 @ 10:27 PM | in 3.0.2

In Rails 3 beta3 mail_to (when used in a view) is not returning a html_safe string.

Code in view:

<%= raw mail_to(supplier.email, h(supplier.email), :subject => "Bathroom Direct Order:", :encode => "javascript") %>

Returns this in the browser:

My temporary solution (code in view) use raw to get a html_safe string:

<%= raw mail_to(supplier.email, h(supplier.email), :subject => "Bathroom Direct Order:", :encode => "javascript") %>

This returns the correct line in the browser: xyz@xyz.com

I believe this needs fixing in the Rails 3 code.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments