Fixed: BUT ! Re: Help: Restful link_to

I think I finally got this to work but wouldn’t mind some confirmation
that this is the right and RESTFUL way.

map.resources :positions, :collection => {:member => :get}

controller:
def description
@position = Position.find(params[:id])
respond_to do |format|
format.html
format.xml {render :xml => @position.to_xml }
end
end

link:
<%= link_to “Preview Description”, :controller => ‘positions’, :action
=> ‘description’, :id => @position.id %>

This make sense and any potential issues ?

TIA
Stuart

On 10/2/06, Dark A. [email protected] wrote:

Stuart


http://en.wikipedia.org/wiki/Dark_ambient


This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs