# Issue with listing a form\_for a collection

**URL:** <https://www.ruby-forum.com/t/issue-with-listing-a-form-for-a-collection/191132>\
**Category:** Rails\
**Created:** [July 6, 2010, 9:48am UTC](https://www.ruby-forum.com/t/issue-with-listing-a-form-for-a-collection/191132 "2010-07-06T09:48:44Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![theprojectabot](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/ce73a5/32.png) [@theprojectabot](https://www.ruby-forum.com/u/theprojectabot)\
**Post date:** [July 6, 2010, 9:48am UTC](https://www.ruby-forum.com/t/issue-with-listing-a-form-for-a-collection/191132/1 "2010-07-06T09:48:44Z")

</div>

I have a @people instance variable that is the return from  
Person.find(:all)

I then want to have a revise.html that allows me to fill out one  
textfield with a number that I can then @people.update\_all(:revision)

I try to do this:REVISION CHANGE

\<% form\_for @people do |f| %\>  
\<%= f.error\_messages %\>

\<%= f.label :version %\>  
 \<%= f.text\_field :version %\>

\<%= f.submit "Update" %\>

\<% end %\>

and it blows up on me with:

undefined method  
`person\_person\_person\_person\_person\_person\_person\_person\_path’ for  
#ActionView::Base:0x101688c90  
Extracted source (around line #3):

1: REVISION CHANGE  
2:  
3: \<% form\_for @people do |f| %\>  
4: \<%= f.error\_messages %\>  
5:

6: \<%= f.label :version %\>

Sorry Im confused by this helper and how it is trying to make the  
form.

---

<div class="post-metadata">

**Author:** ![theprojectabot](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/ce73a5/32.png) [@theprojectabot](https://www.ruby-forum.com/u/theprojectabot)\
**Post date:** [July 6, 2010, 11:52am UTC](https://www.ruby-forum.com/t/issue-with-listing-a-form-for-a-collection/191132/2 "2010-07-06T11:52:08Z")

</div>

theprojectabot wrote:

> I have a @people instance variable that is the return from  
> Person.find(:all)
> 
> I then want to have a revise.html that allows me to fill out one  
> textfield with a number that I can then @people.update\_all(:revision)
> 
> I try to do this:REVISION CHANGE
> 
> \<% form\_for @people do |f| %\>  
> Try to use form\_tag instead of form\_for  
> \<% form\_tag ‘youraction’, :method=\>‘yourmethod’ %\>

> \<%= f.error\_messages %\>
> 
> \<%= f.label :version %\>  
> \<%= f.text\_field :version %\>
> 
> \<%= f.submit "Update" %\>

and label\_tag, text\_field\_tag, submit\_tag helpers, as well

> \<% end %\>

---

<div class="post-metadata">

**Author:** ![theprojectabot](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/ce73a5/32.png) [@theprojectabot](https://www.ruby-forum.com/u/theprojectabot)\
**Post date:** [July 6, 2010, 11:53am UTC](https://www.ruby-forum.com/t/issue-with-listing-a-form-for-a-collection/191132/3 "2010-07-06T11:53:56Z")

</div>

You also may read [Action View Form Helpers — Ruby on Rails Guides](http://guides.rubyonrails.org/form_helpers.html) fbout  
rails form helpers
