Forum: Ruby on Rails One Mailer for all

3275da7fdbd73cb4e7956fd0d29164de?d=identicon&s=25 Paul Bergstrom (palb)
on 2011-03-07 17:53
Can I have one mailer for all? Would that be called
application_mailer.rb
6883e5ef03484d4fcef507d7b4f1d243?d=identicon&s=25 Matt Jones (Guest)
on 2011-03-08 19:38
(Received via mailing list)
On Mar 7, 11:53am, Paul Bergstrom <li...@ruby-forum.com> wrote:
> Can I have one mailer for all? Would that be called
> application_mailer.rb
>

Mailer names are pretty much arbitrary - even the _mailer extension is
just a convention. The biggest downside to "put everything in one
mailer" is the same one any "kitchen sink" file develops, namely a
lack of structure. But there's no *technical* impediment to doing
so...

--Matt Jones
6799ecb7745167d2590d85c4ed25d985?d=identicon&s=25 David Kahn (dkahn)
on 2011-03-08 20:59
(Received via mailing list)
On Tue, Mar 8, 2011 at 12:37 PM, Matt Jones <al2o3cr@gmail.com> wrote:

> lack of structure. But there's no *technical* impediment to doing
> so...
>

Yeah, I even went further and just parameteized one mailer method so
that I
could just pass in whatever text I wanted it to send to who I wanted to
send
it so.... not pretty but for internal stuff does the job.
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.