app/mailers/notification.rb
:class Notification < ActionMailer::Base
default from: "from@example.com"
def new_account(user)
@user = user
headers["X-Priority"] = '3'
mail(:to => user.email,
:subject => "The new account #{user.name} is active.")
end
end
Sent mail to stefan.wintermeyer@amooma.de (50ms)
Date: Wed, 30 May 2012 17:35:21 +0200
From: from@example.com
To: stefan.wintermeyer@amooma.de
Message-ID: <4fc63e39e356a_aa083fe366028cd8803c7@MacBook.local.mail>
Subject: The new account Wintermeyer is active.
Mime-Version: 1.0
Content-Type: text/plain;
charset=UTF-8
Content-Transfer-Encoding: 7bit
X-Priority: 3
Hello Wintermeyer,
your new account is active.
Have a great day!
A Robot