Router :requirements


#1

How to make “:requirements” for router parameter that accept any string
/ any character?

map.page ‘search/:word’, :controller => ‘search’, :requirements => {
:word => ??? }

By default it doesn’t accept “dot” in search word, so:

http://mydomain.com/search/this.is.test returns Error 404 page not
found.


#2

Help ?


#3

At this casts you can see an example:
http://railscasts.com/episodes/70-custom-routes

On Sat, Mar 28, 2009 at 1:08 PM, Fresh M.
<removed_email_address@domain.invalid