\Peter,

On Thu, Apr 28, 2011 at 09:15:05AM -0700, Peter wrote:

> I didn't see anyone in this thread answer your actual, original
> question on here so I figured I'd chime in.  I'm not familiar with the
> Rails 3 routes syntax yet, but I think in Rails 2.x this should be as
> simple as:
> 
>   map.resources :recipes
>   map.connect 'Recipe/:id', :controller => 'recipe', :action => 'show'

Actually, I think I just found the trick for Rails 3 in section 2.5 of
the routing guide - Singular Resources.  It looks like RESTful routes
tailored to my preferences are as simple as:

      resource :recipe, :path => "Recipe"

      match 'Recipes' => 'recipes#index', :as => :recipes, :via => :get

I had tried using singular resources before but mistakenly typed
resources instead of resource.  



-- 

Kevin
http://www.RawFedDogs.net
http://www.WacoAgilityGroup.org
Bruceville, TX

What's the definition of a legacy system?  One that works! 
Errare humanum est, ignoscere caninum.

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