Hello Muhammad,
Your question showed up twice, so answered again.
I assume you''ve already installed action_mailer_optional_tls so I
won''t say to do that.
I use:
ActionMailer::Base.smtp_settings = {
:tls => true,
:address => "smtp.gmail.com",
:port => 25,
:domain => "gmail.com",
:authentication => :login,
:user_name =>
"b........-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org",
:password => "........"
}
But I also needed to make a change to smtp_tls.rb so it would work
with Ruby 1.8.7. Specifically:
Change:
check_auth_args user, secret, authtype if user or secret
To:
check_auth_args user, secret if user or secret
As for some reason check_auth_args went from 3 args to 2.
Rick
On Jan 25, 11:34 pm, mujahid raafay
<raafa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> Dear friends,
> I am new to rails.I am develoing a test application in which i need to
> send email . I have rails 2.2.2
> I have made following changes in application.rb
>
> ActionMailer::Base.delivery_method = :smtp
>
> ActionMailer::Base.smtp_settings = {
> :address => ''smtp.gmail.com'',
> :port => 587,
> :domain => ''gmail.com'',
> :authentication => :plain,
> :user_name =>
''raafa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org'',
> :password => ''lionesss'',
> :tls => true
> }
>
> When i send email I get following message in prompt:
>
-----------------------------------------------------------------------------
>
> Processing AddressBooksController#addFriends (for 127.0.0.1 at 2009-01-26
> 14:23:41) [GET]
> Parameters: {"final"=>"1",
"email0"=>"raafa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org"}
> Redirected to /address_books/sendmail?nameOfSender=muhammad
> Completed in 3ms (DB: 0) | 302 Found
[http://127.0.0.1/address_books/addFriends?final=1&email0=raafay86%40g...
> ]
>
> Processing AddressBooksController#sendmail (for 127.0.0.1 at 2009-01-26
> 14:23:42) [GET]
> Parameters: {"nameOfSender"=>"muhammad"}
> Sent mail to raafa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
>
> Date: Mon, 26 Jan 2009 14:23:42 +0500
> From: raafa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
> To: raafa...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
> Subject: Invitation from BizCar
> Mime-Version: 1.0
> Content-Type: text/plain; charset=utf-8
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
> <html>
> <head>
> <meta http-equiv="Content-Type"
content="text/html;
> charset=iso-8859-1" />
> <title>Untitled Document</title>
> </head>
> <body>
> </body>
> </html>
> Completed in 11ms (View: 0, DB: 0) | 200 OK
[http://127.0.0.1/address_books/sendmail?nameOfSender=muhammad]
>
>
--------------------------------------------------------------------------------------------
>
> The message shows as if the email has been sent but I am receiving no email
> at raafa...-Re5JQEeQqe9fmgfxC/sS/w@public.gmane.org
> If somebody can help me out ......Thankssssss
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---