form_for and scopes, rails 3

前端 未结 7 2081
执念已碎
执念已碎 2020-12-19 05:37

I have a problem due to scopes and the form_for helper in rails 3. The routes - file looks like this:

scope \"(/:tab)\" do
  resources :article
end


        
相关标签:
7条回答
  • 2020-12-19 06:24

    You could specify the path explicitly:

    <%= form_for(@article, :url => article_path(@article, :tab => params[:tab]) %>
    
    0 讨论(0)
提交回复
热议问题