[Rails] rails 3 routes
I'm a little confused about custom routes in rails 3. I have a
variable that I had a default value for in rails 2, and changing it to
rails 3 version gives this:
match 'stories/list/:story_list/:search' => 'stories#index', :as =>
'story_list', :story_list => 'popular', :search => nil
When I use the route, I just call story_list_path(:story_list =>
'search', :search => 'something')
this worked in rails 2, but I'm getting this error in rails 3:
No route matches {:story_list=>"search", :controller=>"stories"}
I can't find out how to fix this as tutorials on the web just go over
basic changes and what not.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home