Posted by Ben Knight (biguniverse) on 28.10.2008 02:28 I realize this has probably been asked on these forums before but I wanted to get the latest information on what''s available. We need to implement the typical "Remember Me" checkbox feature you find for logins on various site. What''s the best way to do this in Rails 1.2.x and 2.x? Should we use cookies[] directly? Or, can I use session[]? We need this "remember me" to be around for at least 2 weeks, maybe even forever (till they logout). 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Hi Ben, I''m afraid you need to use cookies. But it''s not that hard, really ;), and is flexible enough. Please note you might not want to store any sensitive information in cookie also, like username etc. in cleartext - maybe setting up special purpose hash in user model, and storing it also in cookie is good idea. You need also not to forget about situation where user can use "remember me" on multiple computers - otherwise your users will complain. H. On 28 Paź, 02:49, Ben Knight <rails-mailing-l...-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> Posted by Ben Knight (biguniverse) on 28.10.2008 02:28 > I realize this has probably been asked on these forums before but I > wanted to get the latest information on what''s available. > > We need to implement the typical "Remember Me" checkbox feature you find > for logins on various site. > > What''s the best way to do this in Rails 1.2.x and 2.x? Should we use > cookies[] directly? Or, can I use session[]? We need this "remember > me" to be around for at least 2 weeks, maybe even forever (till they > logout). > > Thanks. > -- > Posted viahttp://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-/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 -~----------~----~----~----~------~----~------~--~---
May I reccomend http://www.thewojogroup.com/2008/09/remember-mes-with-rails/ -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
I always use Restful_Authentication (http://github.com/technoweenie/ restful-authentication). Even if you don''t want to use that, I suggest you take a look at how it handles it. HTH Ben Knight wrote:> Posted by Ben Knight (biguniverse) on 28.10.2008 02:28 > I realize this has probably been asked on these forums before but I > wanted to get the latest information on what''s available. > > We need to implement the typical "Remember Me" checkbox feature you find > for logins on various site. > > What''s the best way to do this in Rails 1.2.x and 2.x? Should we use > cookies[] directly? Or, can I use session[]? We need this "remember > me" to be around for at least 2 weeks, maybe even forever (till they > logout). > > 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Thanks everyone. -- 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---