How to: use one form for updating an entry which the user specifies by.e.g., click on it

Hello, thank you for paying attention to my post! So basically, I have
a list of entries:
<% for x in Chore.find(:all) %>

  • <%= x.title %>
  • <% end %>

    <%= form_tag :url => {:controller => ‘chore’, :action => ‘update’} do
    <%= text_field_tag :title %>
    <%= submit_tag %>
    <% end %>

    Let’s say, one chore entry is spelled incorrectly and I would like to
    change it, could I do something as clicking on the title and then it
    shows up in the text field, then I change the spelling and hit submit?

    The difficulty I encountered is how one passes the “id” to the URL so
    that the update “knows” whom to update.

    Thank You A Million!!

    Yeah, take a look into in-place editing.


    Learn Ruby on Rails! Check out the FREE VIDS (for a limited time)
    VIDEO #3 out NOW!

    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