title: undefined method user_path' form_for
body: <p>I have a UsersController and it has below code</p>
  
  <pre><code>def sign_up
  @user = User.new
  end
  </code></pre>
  
  <p>And my view page has</p>
  
  <pre><code>&lt;div class="col-md-6 col-md-offset-3"&gt;
      &lt;%= form_for @user do |f| %&gt;
        &lt;%= f.label :first_name%&gt;
        &lt;%= f.text_field :first_name %&gt;
        &lt;%= f.label :last_name %&gt;
        &lt;%= f.text_field :last_name %&gt;
        &lt;%= f.submit "Register", class: 'btn btn-primary'%&gt;
      &lt;% end %&gt;
    &lt;/div&gt;
  </code></pre>
  
  <p>My routes.rb file contains the following entry</p>
  
  <pre><code> get 'signup' =&gt; 'users#sign_up'
  </code></pre>
  
  <p>But When I submit the form, it says </p>
  
  <pre><code>ActionView::Template::Error (undefined method `users_path' for #&lt;#&lt;Class:0x00000004d91490&gt;:0x00000004d90220&gt;)
  </code></pre>
  
  <p>Why does this throw an error and do I need to explicity point to url in the form_for?? Why is it so??</p>