Ruby on Rails Wednesday, August 31, 2011

I have the following problem:
- I have a controller called UsersController and I need to restrict
the show URL to use only numbers, How can I do that?
my routes.rb has this line:
resources :users, :except=>[:destroy]
How I add this constraint in this line?
I know that there is a command :constraints, but I dont know how to
use in resources ;/
Thanks :D

--
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.

No comments:

Post a Comment