GeoRSS aggregator and Layar augmented reality server
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

sessions_controller.rb 415 B

12 jaren geleden
12345678910111213141516171819
  1. class SessionsController < ApplicationController
  2. def new
  3. end
  4. def create
  5. user = login(params[:email], params[:password], params[:remember_me])
  6. if user
  7. redirect_back_or_to root_url, :notice => "Logged in OK"
  8. else
  9. flash.now.alert = "Email or password was invalid"
  10. render :new
  11. end
  12. end
  13. def destroy
  14. logout
  15. redirect_to root_path, :notice => "Logged out"
  16. end
  17. end