Hello, there: I create the following controller and view to handle login and logou, but the form_tag always said "undefined local variable or method `session_path'' for #<ActionView::Base:0xb590e7e0>" when I try open the "login" (new) page. Any idea why? Thanks! ==================Controller ==================class SessionsController < ApplicationController def new end def create self.current_user = User.authenticate(params[:login], params[:password]) if logged_in? if params[:remember_me] == "1" self.current_user.remember_me cookies[:auth_token] = { :value => self.current_user.remember_token , :expires => self.current_user.remember_token_expires_at } end redirect_back_or_default(''/'') flash[:notice] = "Logged in successfully" else render :action => ''new'' end end =========View =========<% form_tag session_path do -%> <p><label for="login">Login</label><br/> <%= text_field_tag ''login'' %></p> <p><label for="password">Password</label><br/> <%= password_field_tag ''password'' %></p> <p><%= check_box_tag ''remember_me'' %><label for="remember_me">Remember me:</label> </p> <p><%= submit_tag ''Log in'' %> <%= link_to "Forgot Password?", forgot_password_url %></p> <% end -%> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---