Follow up - looks like the router is choking on the periods. Without those it 
is fine.

I could just transform . into _ to have routes like
/places/40_728601/-73_991972

Any thoughts? Any better way to go about this (while using bound parameters as 
opposed to query strings to keep with the spirit of distinct, meaningful URI's?

Best Wishes,
Peter

Begin forwarded message:

> From: Peter Bell <pe...@pbell.com>
> Date: February 16, 2011 6:02:13 PM EST
> To: rubyonrails-talk@googlegroups.com
> Subject: Limitations on parameters in routes?
> 
> I have the following route:
> 
> get "/places/:lat/:lng" => "api#places"
> 
> When I go to /places/1/2 it works fine
> When I try to go to /places/40.728601/-73.991972 (a useful lat/lng) I get a 
> Routing error: No route matches "/api/v11/places/40.728601/-73.991972"
> 
> Any suggestions on how I can get this working? I know I could put the latlng 
> into a query string, but it seems a little more RESTful to have it as part of 
> the URI.
> 
> Best Wishes,
> Peter

-- 
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+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to