Hi all! In Rails 2.3, I could do the following: map.connect "/posts/favorites", :controller => :posts, :action => ":index", :filter => "favorites" But it seems that the "match" command in Rails 3 doesn''t accept parameters. So, the following doesn''t work: match "/posts/favorites" => "posts#index", :filter => "favorites" Is there any way to pass a parameter in route like in 2.3 ? Thank you! -- Posted via http://www.ruby-forum.com/. -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Sorry to ask again, but no one know how to do this? I have read all the routes section in Rails Guides ( http://guides.rails.info/routing.html ) but didn''t find a way to pass parameters in routes. Maybe this feature was removed from Rails 3? -- Posted via http://www.ruby-forum.com/. -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On Thu, Feb 11, 2010 at 5:32 PM, Henrique Testa <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> Sorry to ask again, but no one know how to do this? I have read all the > routes section in Rails Guides ( http://guides.rails.info/routing.html ) > but didn''t find a way to pass parameters in routes. > > Maybe this feature was removed from Rails 3?I''d file a bug report.. if it''s missing on purpose they will surely tell you. -- Greg Donald destiney.com | gregdonald.com -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
> I''d file a bug report.. if it''s missing on purpose they will surely tell > you.Just discovered a way, using :default => { :filter =>"favorites" } Unfortunately, it doesn''t work :) But it is on Rails Guides. I just filled a bug report here https://rails.lighthouseapp.com/projects/16213/tickets/119-default-route-option-doesnt-work -- Posted via http://www.ruby-forum.com/. -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
This has been around for a long time, but just in case somebody stumbles across it like I did, it should be ":defaults => ..." not "default => ..." On Friday, 12 February 2010 02:33:40 UTC+1, Ruby-Forum.com User wrote:> > > I''d file a bug report.. if it''s missing on purpose they will surely tell > > you. > > Just discovered a way, using :default => { :filter =>"favorites" } > > Unfortunately, it doesn''t work :) But it is on Rails Guides. I just > filled a bug report here > > https://rails.lighthouseapp.com/projects/16213/tickets/119-default-route-option-doesnt-work > -- > Posted via http://www.ruby-forum.com/. > >-- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/365fdP7g9M0J. For more options, visit https://groups.google.com/groups/opt_out.