# ActionMailer template issues?

**URL:** <https://www.ruby-forum.com/t/actionmailer-template-issues/89470>\
**Category:** Rails\
**Created:** [March 20, 2007, 6:46pm UTC](https://www.ruby-forum.com/t/actionmailer-template-issues/89470 "2007-03-20T18:46:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dwfrank](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/f1d935/32.png) [@dwfrank](https://www.ruby-forum.com/u/dwfrank)\
**Post date:** [March 20, 2007, 6:46pm UTC](https://www.ruby-forum.com/t/actionmailer-template-issues/89470/1 "2007-03-20T18:46:17Z")

</div>

I’m using ActionMailer and it’s working fine when actually sending  
mail. I have a TestEmailController whose job it is to render sample  
versions of each email we send and show them in a browser for review  
by QA & our creative teams.

Currently, I’m using the create\_\* method in ActionMailer, and then  
trying render :text =\> email.part[1]. When I do this, the text/html  
email part appears to be encoded for SMTP (I know zero about SMTP) and  
so I’ve got 3Ds and linebreaks all over my code. Is there some way to  
convert the email part back to HTML for rendering in a browser?

Initially, I was trying to render the html template directly, but  
there are some oddities around the template search path in partials  
below the main RHTML template I’m using, so I went back to the first  
method. I’ll go back to direct template rendering if folks think  
that’s a better way…

thx,  
–dwf
