Mailer related query

I am putting this in my mailer view…which sends message to some
id.
suppose [email protected]

Hi!
You are having one email message from <%= @email %> with a title
<%= @title %>
and following is the message:
Confirm
Thanks


On checking it on rediffmail or gmail server,

I am getting same thing

Hi!
You are having one email message from <%= @email %> with a title
<%= @title %>
and following is the message:
Confirm
Thanks

Not getting link to Confirm…

Don’t know why?

Do you get links on other than gmail or rediff?

Do you have action mailer instance under model folder? Have defined
methods within it?

Here is a brief;

ruby script/generate mailer Notify

This should generate the following in your model directory and under
folder in your view.

class Notify < ActionMailer::Base
end

now, you define methods with in models/notify.rb

class Notify < ActionMailer::Base

def notifycustomer(blahh, blah)
@subject = “Message from a visitor”
@recipients = blahh.email
@from = blah[:email]
@sent_on = Time.now
@body[“title”] = blah[:msg]
end
end

in your controllers action you would trigger it

def sendmail2customer
Notify.deliver_notifycustomer(@blahh, params[:blah])
end

in your view, you will have sendmail2customer.html.erb which might have

Hi!
You are having one email message from <%= @email %> with a title
<%= @title %>
and following is the message:
Confirm
Thanks

let me know how it goes

Rails L. wrote:

Do you get links on other than gmail or rediff?

Do you have action mailer instance under model folder? Have defined
methods within it?

Here is a brief;

ruby script/generate mailer Notify

This should generate the following in your model directory and under
folder in your view.

class Notify < ActionMailer::Base
end

now, you define methods with in models/notify.rb

class Notify < ActionMailer::Base

def notifycustomer(blahh, blah)
@subject = “Message from a visitor”
@recipients = blahh.email
@from = blah[:email]
@sent_on = Time.now
@body[“title”] = blah[:msg]
end
end

in your controllers action you would trigger it

def sendmail2customer
Notify.deliver_notifycustomer(@blahh, params[:blah])
end

in your view, you will have sendmail2customer.html.erb which might have
===============================================================================
Hi!
You are having one email message from <%= @email %> with a title
<%= @title %>
and following is the message:
Confirm
Thanks
=============================================================================
I am getting this
Hi!
You are having one email message from [email protected] with a title
Confirmation
and following is the message:
Confirm
Thanks

you have to replace the variables with your own

def notifycustomer(blahh, blah)
@subject = “Message from a visitor”
@recipients = blahh.email
@from = blah[:email]
@sent_on = Time.now
@body[“title”] = blah[:title] #now you can use @title in your view
@body[“msg”] = blah[:msg] # now you can use @msg in your view
@body[“url”] = “some url” # now you can use @url in your view
end

if you have followed my sample code then your view should have

Hi!
You are having one email message from <%= @email %> with a title
<%= @title %>
and following is the message:
<%= @msg %>
url: <%= @url %>

Thanks