Connecting Tech Pros Worldwide Forums | Help | Site Map

Send email in Rails 2.0

Newbie
 
Join Date: Oct 2007
Posts: 19
#1: Jan 27 '09
Hello,
I am using Rails 2.0 in which i want to send email.Where do i configure the gmail settings?If i add the settings in environment.rb file as older version,the application is not running.I am using tlsmail gem.Please help me to solve this.I need this setting to be added in rails 2.0
Expand|Select|Wrap|Line Numbers
  1. require 'tlsmail'
  2. Net::SMTP.enable_tls(OpenSSL::SSL::VERIFY_NONE)
  3.  
  4. ActionMailer::Base.delivery_method = :smtp
  5. ActionMailer::Base.server_settings = {
  6. :address => 'smtp.gmail.com',
  7. :tls => 'true',
  8. :port => 587,
  9. :domain => 'gmail.com',
  10. :authentication => :plain,
  11. :user_name => ' ',
  12. :password => ' '
  13. }
Thanks.

Regards,
amulyab

Expert
 
Join Date: May 2007
Posts: 216
#2: Jan 27 '09

re: Send email in Rails 2.0


Google gave me these pages that might have some helpful info: link, link

Also, please use code tags when posting code in the future. They make the code stand out and make it easier to read.
Reply


Similar Ruby / Ruby on Rails bytes