When I first started using Rails, actionmailer set email header values by assigning values to instance variables within a model method. There were some specific instance variables such as ''subject'', ''from'', etc. Header values for which there was no specific instance variable assigned could be set using the @headers hash. This hash could be used to set the Reply-To header value. Somewhere along the line things got changed so that methods were used to set header values instead of instance variables. That''s the way things work in the version of Rails that I am currently using (2.3.8). Unfortunately, up until now, I have never had the need to set a Reply-To header in version 2.3.8 of Rails. That is now what I''m trying to do. Unfortunately, the on-line documentation for actionmailer addresses Rails version 3.0 which uses a different methodology. So, my question is this: Can someone please tell me what I need to do to set the Reply-To header value in version 2.3.8 of Rails? Thanks for any input. ... doug -- 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.
Bryan Crossland
2011-Apr-16 05:44 UTC
Re: ActionMailer - Setting Header Values - Version Issues
On Fri, Apr 15, 2011 at 11:39 AM, doug <ddjolley-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> When I first started using Rails, actionmailer set email header values > by assigning values to instance variables within a model method. > There were some specific instance variables such as ''subject'', ''from'', > etc. Header values for which there was no specific instance variable > assigned could be set using the @headers hash. This hash could be > used to set the Reply-To header value. > > Somewhere along the line things got changed so that methods were used > to set header values instead of instance variables. That''s the way > things work in the version of Rails that I am currently using > (2.3.8). Unfortunately, up until now, I have never had the need to > set a Reply-To header in version 2.3.8 of Rails. That is now what I''m > trying to do. > > Unfortunately, the on-line documentation for actionmailer addresses > Rails version 3.0 which uses a different methodology. > > So, my question is this: Can someone please tell me what I need to do > to set the Reply-To header value in version 2.3.8 of Rails? > > Thanks for any input. > >The apidock.com site has the information for all versions so rails. When you do a good search it will always show you the latest version of rails when the apidock.com is the link. You can click the version numbers at the top of the page to see what the same api is for another version. Here is the link to ActionMailer::Base for Rails 2.3.8. I think you will find what you need there for setting your reply-to header value. http://apidock.com/rails/v2.3.8/ActionMailer/Base B. -- 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.
Perfecto! Thanks so much. ... doug -- 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.