jondot/padrino-warden — Issue #5: Full usage example?
Author: jordanlev
Created: 2011-12-08 01:06:28+00:00
State: open

Hi. Thank you very much for putting this module together.
I am a total sinatra/padrino n00b (I have some ruby experience, but certainly not a super expert). I'm trying to wrap my head around how to build out my website using warden for authorization/authentication. I understand how to install the gem and put the code into my padrino project. And I understand how to use the authorize! method in my controllers to restrict access to pages. But I'm confused about how I set things up for login workflow. I created a login view and that is successfully being shown when an authorize! check fails. But if I try to log in with an incorrect password, I'm not brought back to the login page itself, but rather to some page I don't have implemented (and I believe it's trying to look for it in a different app within my project -- but I don't understand this because I want to display an error message on the login page itself so the user can try again, not go to some other page in some other section of my website).

Thanks for any help you can provide in how to implement the full workflow for password login and registration.

-Jordan