title: Action 'index' could not be found for <x>Controller
body: <p>So I have just created my rails 4.1.2 project with a controller, <code>login_controller.rb</code> and view <code>login.html.erb</code>. I have edited my <code>routes.rb</code> and removed the already put in route by rails after creating a controller and added another default <code>match</code> route which is <code>:controller(/:action(/:id))', :via =&gt; :get</code></p>
  
  <p>When I run my server using <code>rails s</code> and open <code>localhost:3000/login</code> it gives me this error:</p>
  
  <pre><code>The action 'index' could not be found for LoginController
  </code></pre>
  
  <p>I do not know why is it looking for an action named 'index'. If I am right then the default action taken by rails without actually specifying one is 'index' so I tried to change my URL and requested this:</p>
  
  <pre><code>localhost:3000/login/login
  </code></pre>
  
  <p>Which gave me this error:</p>
  
  <pre><code>No route matches [GET] "/login/login"
  </code></pre>
  
  <p>How can I fix this issue? Thanks.</p>
  
  <p>Here's what my <code>rake routes</code> outputs:</p>
  
  <pre><code>Prefix Verb URI Pattern                             Controller#Action
         GET  /:controller(/:action:(/:id))(.:format) :controller#:action
  </code></pre>