Hello, I''m a newbie in the rails environment, I''m now busy with the plugin restful_authentication. I''ve signed me up without any problems but when I try to log me on the page/login via the form, nothing happens, I see always the page "login" without any changes? No error messages, nothing... Definitively I would like to be able to connect me as "admin" and directly go to the section "admin". I''ve already created a file admin (controllers/admin) within the specific "admin" controllers. When I type www.monsite.com/admin, I arrive directly on the page "login" but afterwards nothing happens :s Could you please help me? Thanks you! -- 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 -~----------~----~----~----~------~----~------~--~---
You might have signed up, but are you activated?
I''m not using parts of restful_authentication, users "sign
up" by
emailing me, and I''ll create their user for them (kinda old school I
guess)... so I changed a portion of the user model code to avoid the
activation stuff.
def self.authenticate(login, password)
#u = find :first, :conditions => [''login = ? and enabled = ? and
activated_at IS NOT NULL'', login, true] # need to get the salt
u = find :first, :conditions => [''login = ?'', login] #
need to get
the salt
u && u.authenticated?(password) ? u : nil
end
I also edited the user migration to construct the admin user and set its
password. First step after migrating is to login as admin, and create my
personal login.
--
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 you, that works perfectly! -- 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 -~----------~----~----~----~------~----~------~--~---