send email from localhost

Update for rails 4.0
Now you need these code to make it work:

# I recommend using this line to show error
config.action_mailer.raise_delivery_errors = true

ActionMailer::Base.smtp_settings = {
  :address        => 'smtp.gmail.com',
  :domain         => 'mail.google.com',
  :port           => 587,
  :user_name      => '[email protected]',
  :password       => '******',
  :authentication => :plain,
  :enable_starttls_auto => true
}

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)