Rails url_for not finding the route which appears in Rake Routes? -
i have following rake routes:
user /users/:id(.:format) {:action=>"show", :controller=>"users"}
but when do, email template:
<%= link_to(@comment.user.full_name, user_url(:only_path => false), :style => 'color:#5196e3;text-decoration:underline;') %>
i following error: "actionview::template::error (no route matches {:action=>"show", :controller=>"users"}):"
thoughts? thanks
if @ route needs :id parse. should supply user this:
user_url(@comment.user, :only_path => false)
Comments
Post a Comment