Dear all rails developers,
I want to create a login page. Could any one show me how to create a signup and signin pages. i have try follow many websites but i can not do it. please help me, thanks,
veasna
Dear all rails developers,
I want to create a login page. Could any one show me how to create a signup and signin pages. i have try follow many websites but i can not do it. please help me, thanks,
veasna
I assume that you are a beginner to Rails and therefore suggest working right through a good tutorial such as railstutorial.org (which is free to use online). This includes a user login/logout.
Also there are several good gems that will make this easy, such as Devise. However, first do work through that tutorial as that will show you the basics of rails.
Colin
This screencast should be useful:
http://railscasts.com/episodes/250-authentication-from-scratch
I suggest read/study about authentication a little before starting using gems like ‘Devise’.
Thanks Colin I will try it.
Thanks Antônio Augusto Sousa Britto I will try it.
Dear Mr. Colin
I have completed create log_in page. After log_in successfully i want to link to my page that i have create it in user folder. so could you show me how to do. thanks.
veasna
Dear Mr. Colin
I have completed create log_in page. After log_in successfully i want to link to my page that i have create it in user folder. so could you show me how to do. thanks.
Have you worked right through the tutorial I suggested? If you do that you will certainly know how to answer your own question (and also a hundred other questions that you will need to know the answers to).
Colin
Yes, it work when i register then i’m log_in when success it redirect to sign_up page, so i want when log_in success redirect to my page. i use this command “redirect_to root_url(‘users/home’), :notice => “Logged In!”” it not run my home page. could you tell me why? thanks you.
veasna
Yes, it work when i register then i'm log_in when success it redirect to sign_up page, so i want when log_in success redirect to my page. i use this command "redirect_to root_url('users/home'), :notice => "Logged In!"" it not run my home page. could you tell me why?
One of the things you would have learnt if you worked through the tutorial is how to work out what is going wrong. For instance to look in log/development.log to get more information about what is happening. Please work through the tutorial so you will not be embarrassed when you look back through these questions later and wonder why you needed to ask for help.
Colin