Forum: Ruby on Rails Format parameter in RESTful named routes

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
F070854cc14336e45e61c2f2c76850a7?d=identicon&s=25 Ben Lund (Guest)
on 2007-03-12 18:44
(Received via mailing list)
In my application I have a RESTful named route:

map.resources :discussions

And I'm attempting to generate a URL like:


using the discussion_url helper method.

The following:

discussion_url(:id =>, :format => 'atom')

just generates /discussions/27, ignoring the format parameter.

Anyone know the correct way of doing this? As far as I can see, the
docs have nothing to say on the matter.

A99870c1391c39da2089649745965bda?d=identicon&s=25 Jean-François Trân (Guest)
on 2007-03-12 18:49
(Received via mailing list)
Ben :
> The following:
> discussion_url(:id =>, :format => 'atom')

formatted_discussion_url(:id =>, :format => :atom)

   -- Jean-François.

Ruby ( ) on Rails (
This topic is locked and can not be replied to.