/ Published in: Ruby
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
def check_authentication unless session[:admin] session[:intended_action] = action_name session[:intended_controller] = controller_name redirect_to :action => "signin" end end