button, so when i click on that button, gives no routes matches :controller
=> 'home', :action => 'login'. But i have put that in routes.rb. Why this
happening?
*view.html.erb*
<%= form_tag( { :controller => 'home', :action => 'login' }, { :method => 'post'}) do %>
<%= text_field(:name, :name, :class => "span2",:placeholder => "Username") %>
<%= password_field_tag(:password, :password, :class =>"span2") %>
<%= submit_tag "Login", :class => "btn btn-primary" %>
<% end %>
routes.rb
resources :home do
post :login, :on => :member
end
homecontroller.rb
class HomeController < ApplicationController
def login
end
end
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/dwIdjTTKPmwJ.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.