Rails3: form_for and namespaced controllers

Montag, 25. April 2011, 20:36 Uhr | roberto@vasquez-angel.de |

Assume you have a Customer model and a namespaced controller for handling customers:

class Platform::Backend::CustomersController < Platform::BackendController
  .
  .
  .
end  

Then, the right form_for tag is the following:

<%= form_for([:platform_backend, @customer]) do |f| %>
  .
  .
  .
<% end %>