URL tracking

Hi guys....

I want to keep track all urls of my rails application.

Suppose i m not logged in.......... i am clicking the links......after
logging in i should come to that page which i viewed last time (in
not logged in mode).
can anyone tel me the logic...or how to keep track of the url of the
website.

ripan

There’s a method called stored_location in authenticated_system that can help with this. To use it call it in a before_filter in your controller:

before_filter :store_location, :only => [:show]

and then when you want to redirect back to that action,

redirect_back_or_default root_path