我從耙路線如下:Rails url_for找不到出現在Rake Routes中的路線?
user GET /users/:id(.:format) {:action=>"show", :controller=>"users"}
但是,當我這樣做,爲的電子郵件模板:
<%= link_to(@comment.user.full_name, user_url(:only_path => false), :style => 'color:#5196E3;text-decoration:underline;') %>
我得到以下錯誤:「::的ActionView ::模板錯誤(沒有路由匹配{:action =>「show」,:controller =>「users」}):「
想法?謝謝
`:風格=> 'COLOR:#5196E3;文字修飾:強調;'' - 我認爲這將是更好把它放在你的CSS中。 – Zaz 2013-05-17 11:51:45