Re: [Rails] Clearly Defined Route Not Found
On May 15, 2012, at 6:53 PM, Neil Chaudhuri wrote:
> In routes.rb I have this:
>
> resources :presentations do
> post "save_stuff", :on => :member
> end
>
> In PresentationsController I have this:
>
> def save_stuff
> ...
> end
>
> And in my form I have this:
>
> <%= form_for @presentation, :url => {:action => "save_stuff"}, :html =>
> {:id => "presentationForm", :method => :post} do |f| %>
>
> Yet when an attempt is made to render the above form I get this:
>
> !! Unexpected error while processing request: No route matches
> {:action=>"save_stuff", :controller=>"presentations"}
>
> I have been struggling with this for hours, so I could use some help.
What do you see when you type rake routes in Terminal?
Walter
--
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@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.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home