【发布时间】:2009-09-05 18:18:23
【问题描述】:
在我的 routes.rb 中我有:
map.connect ':name',
:controller => 'my_classes',
:action => 'show'
而且效果很好,所以像这样的 url 会发送这样的参数:
http://localhost:30000/awesome
Parameters: {"name"=>"awesome"}
但是如果我有这样的事情我会得到这个错误:
http://localhost:30000/weak.sauce
ActionController::RoutingError (No route matches "/weak.sauce" with {:method=>:get}):
我该如何解决这个问题?
【问题讨论】:
标签: ruby-on-rails routes actioncontroller