Hi All, I am trying to send an email on a user sign up. The email is working without any issues. However there is a problem with the :from field that I am specifying. My SMTP setting look like : ActionMailer::Base.smtp_settings = { :address => "smtp.gmail.com", :port => "587", :domain => "test.com", :user_name => "support-J0of1frlU80@public.gmane.org", :password => "secret", :authentication => "plain", :enable_starttls_auto => true } and my mailer class looks like, class TestMailer < ActionMailer::Base def registration_confirmation(user) @user = user mail(:to => "#{@user.capitalized_name} <#{@user.email}>", :subject => "Welcome", :from => ''registration-do-not-reply-J0of1frlU80@public.gmane.org'') end end When the email gets sent, in the console I see that the following : Sent mail to xxxxxxx-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org (2846ms) Date: Mon, 08 Nov 2010 20:05:26 -0600 From: registration-do-not-reply-J0of1frlU80@public.gmane.org To: Test <xxxxxxx-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org> Message-ID: <xxxxx-HY7XF+E3qhm3Gk7reEmhgQ@public.gmane.org> Subject: Welcome Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit <p>Dear xxxxxxx,</p> <p>Welcome </p> Everything looks good till here. However when I receive the email, I see from email address shows as the "support-J0of1frlU80@public.gmane.org" instead of registration-do-not-reply-J0of1frlU83hvxM+mQhndA@public.gmane.org Any pointers as to why that might be happening or how I can fix this will be greatly appreciated. Thanks, Vishy -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On Nov 8, 2010, at 6:44 PM, vishy wrote:> Hi All, > > I am trying to send an email on a user sign up. The email is working > without any issues. However there is a problem with the :from field > that I am specifying. My SMTP setting look like : > > ActionMailer::Base.smtp_settings = { > :address => "smtp.gmail.com", > :port => "587", > :domain => "test.com", > :user_name => "support-J0of1frlU80@public.gmane.org", > :password => "secret", > :authentication => "plain", > :enable_starttls_auto => true > } > > and my mailer class looks like, > > class TestMailer < ActionMailer::Base > > def registration_confirmation(user) > @user = user > mail(:to => "#{@user.capitalized_name} <#{@user.email}>", :subject > => "Welcome", :from => ''registration-do-not-reply-J0of1frlU80@public.gmane.org'') > end > end > > When the email gets sent, in the console I see that the following : > > Sent mail to xxxxxxx-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org (2846ms) > Date: Mon, 08 Nov 2010 20:05:26 -0600 > From: registration-do-not-reply-J0of1frlU80@public.gmane.org > To: Test <xxxxxxx-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org> > Message-ID: <xxxxx-HY7XF+E3qhm3Gk7reEmhgQ@public.gmane.org> > Subject: Welcome > Mime-Version: 1.0 > Content-Type: text/html; > charset=UTF-8 > Content-Transfer-Encoding: 7bit > > <p>Dear xxxxxxx,</p> > > <p>Welcome </p> > > Everything looks good till here. However when I receive the email, I > see from email address shows as the "support-J0of1frlU80@public.gmane.org" instead of > registration-do-not-reply-J0of1frlU83hvxM+mQhndA@public.gmane.org > > Any pointers as to why that might be happening or how I can fix this > will be greatly appreciated.I''ve never used google to send mail, but maybe they force that on you. Technically the message is from support-J0of1frlU83hvxM+mQhndA@public.gmane.org Maybe you can set Reply-To: registration-do-not-reply-J0of1frlU80@public.gmane.org instead? That might be enough for your purposes... -philip -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
hi vishy! It seems that u want ur form email id as '' registration-do-not-reply-J0of1frlU80@public.gmane.org'' . For that u have give this email id in smtp settings.. That is user_name has to be set as the following email_id.. I think it will work.. Please try it.. On Tue, Nov 9, 2010 at 8:14 AM, vishy <shubhambansal15-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi All, > > I am trying to send an email on a user sign up. The email is working > without any issues. However there is a problem with the :from field > that I am specifying. My SMTP setting look like : > > ActionMailer::Base.smtp_settings = { > :address => "smtp.gmail.com", > :port => "587", > :domain => "test.com", > :user_name => "support-J0of1frlU80@public.gmane.org", > :password => "secret", > :authentication => "plain", > :enable_starttls_auto => true > } > > and my mailer class looks like, > > class TestMailer < ActionMailer::Base > > def registration_confirmation(user) > @user = user > mail(:to => "#{@user.capitalized_name} <#{@user.email}>", :subject > => "Welcome", :from => ''registration-do-not-reply-J0of1frlU80@public.gmane.org'') > end > end > > When the email gets sent, in the console I see that the following : > > Sent mail to xxxxxxx-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org (2846ms) > Date: Mon, 08 Nov 2010 20:05:26 -0600 > From: registration-do-not-reply-J0of1frlU80@public.gmane.org > To: Test <xxxxxxx-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org> > Message-ID: <xxxxx-HY7XF+E3qhm3Gk7reEmhgQ@public.gmane.org> > Subject: Welcome > Mime-Version: 1.0 > Content-Type: text/html; > charset=UTF-8 > Content-Transfer-Encoding: 7bit > > <p>Dear xxxxxxx,</p> > > <p>Welcome </p> > > Everything looks good till here. However when I receive the email, I > see from email address shows as the "support-J0of1frlU80@public.gmane.org" instead of > registration-do-not-reply-J0of1frlU83hvxM+mQhndA@public.gmane.org > > Any pointers as to why that might be happening or how I can fix this > will be greatly appreciated. > > Thanks, > Vishy > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to > rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org<rubyonrails-talk%2Bunsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> > . > For more options, visit this group at > http://groups.google.com/group/rubyonrails-talk?hl=en. > >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Hi, I have the same SMTP settings. I''m just sending emails to myself to test out. I do the see the sent mail in the console. But I don''t receive any email. The SMTP settings was working with Rails 2.3.8. Any ideas? Thanks! -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.