Suppose I have a resource such as http://localhost:3000/topsecret/data
that requires the user to login first.
What I did was make use of before_filter to check and see if the session
variable is set with the logged in user’s id (similar to the example in
“Agile Web D. with Rails”).
However while the filtering function does work correctly in redirecting
the user to the login page, how do I actually capture the original
request made by the user so that I can redirect the user back to the
required resource after s/he has logged in?