[Rails] Re: Email section

2010-03-12 Thread Manish Belsare
class UserMailer < ActionMailer::Base def reminder(user) @subject = 'Your login information at KnowledgeEngine.com' @body = {} #Give body access to the user information. @body["user"] = user @recipients = user.email @from = 'KnowldegeEngine ' end def mess

[Rails] Re: Email section

2010-03-12 Thread Manish Belsare
class EmailController < ApplicationController include ProfileHelper before_filter :protect, :only => [ "correspond" ] def remind @title = "Mail me my login information" if param_posted?(:user) email = params[:user][:email] user = User.find_by_email(email) if user

[Rails] Re: Email section

2010-03-11 Thread Punit Rathore
Manish, >/root/ksmm/app/controllers/email_controller.rb:12:in `remind' It says there is an error on line 12. I'm guessing this is the line UserMailer.deliver_reminder(user) You might want to paste the code for that method too. Punit -- Posted via http://www.ruby-forum.com/. -- You

[Rails] Re: Email section

2010-03-10 Thread Manish Belsare
def remind @title = "Mail me my login information" if param_posted?(:user) email = params[:user][:email] user = User.find_by_email(email) if user UserMailer.deliver_reminder(user) flash[:notice] = "Login information was sent." redirect_to :action

[Rails] Re: Email section

2010-03-10 Thread Manish Belsare
Sir for the following suggestion it works well.. > config.action_mailer.smtp_settings But wen i further implement it.. It givs the following error: getaddrinfo: Temporary failure in name resolution Application Trace: /usr/lib/ruby/1.8/net/protocol.rb:206:in `initialize' /usr/lib/ruby/1.8/net/

[Rails] Re: Email section

2010-03-10 Thread Andrius Chamentauskas
Hi, It was probably for old action mailer. You should use config.action_mailer.smtp_settings On Mar 10, 8:04 am, Manish Belsare wrote: > Sir , I want to implement email section in ma web application.. > so i found the method 'server_setting' for it... > Following is the method: > > config.action