title: ruby rails - undefined local variable or method `new_user_session_path'
body: <p>Running Rails 3. 
  Included "include Rails.application.routes.url_helpers" in model file of users. Still getting this error. Any idea?? </p>
  
  <pre><code># cat app/models/user.rb
  class User &lt; ActiveRecord::Base
  include Rails.application.routes.url_helpers
  acts_as_authentic
  end
  
  # rake routes
      users GET    /users(.:format)          users#index
            POST   /users(.:format)          users#create
   new_user GET    /users/new(.:format)      users#new
  edit_user GET    /users/:id/edit(.:format) users#edit
       user GET    /users/:id(.:format)      users#show
            PUT    /users/:id(.:format)      users#update
            DELETE /users/:id(.:format)      users#destroy
       root        /                         users#index
  
  
  # cat config/routes.rb | grep -v '#'
  www::Application.routes.draw do
   resources :users
  end
  </code></pre>
  
  <p>Error -</p>
  
  <pre><code>Showing /var/www/app/views/users/index.html.erb where line #7 raised:
  
  undefined local variable or method `new_user_session_path' for #&lt;#&lt;Class:0x9a51c6c&gt;:0x9bb6170&gt;
  Extracted source (around line #7):
  
  4:   
  5: &lt;p&gt;Public Facing Content&lt;/p&gt;  
  6:   
  7: &lt;%= link_to 'Login', new_user_session_path %&gt;
  </code></pre>