# Update form text\_field on collection\_select selection

**URL:** <https://www.ruby-forum.com/t/update-form-text-field-on-collection-select-selection/194106>\
**Category:** Rails\
**Created:** [August 30, 2010, 1:53pm UTC](https://www.ruby-forum.com/t/update-form-text-field-on-collection-select-selection/194106 "2010-08-30T13:53:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![amabdelsalam](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/958977/32.png) [@amabdelsalam](https://www.ruby-forum.com/u/amabdelsalam)\
**Post date:** [August 30, 2010, 1:53pm UTC](https://www.ruby-forum.com/t/update-form-text-field-on-collection-select-selection/194106/1 "2010-08-30T13:53:00Z")

</div>

I have form and a collection\_select control. I would like to update  
form fields (text box) when I select an item from the collection\_select  
box.

It’s like selecting template from the collection\_select and the template  
automatically loads to text boxes.

Any help?

---

<div class="post-metadata">

**Author:** ![amabdelsalam](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/958977/32.png) [@amabdelsalam](https://www.ruby-forum.com/u/amabdelsalam)\
**Post date:** [August 30, 2010, 3:28pm UTC](https://www.ruby-forum.com/t/update-form-text-field-on-collection-select-selection/194106/2 "2010-08-30T15:28:42Z")

</div>

On 30 August 2010 12:53, Ahmed A. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> I have form and a collection\_select control. I would like to update  
> form fields (text box) when I select an item from the collection\_select  
> box.
> 
> It’s like selecting template from the collection\_select and the template  
> automatically loads to text boxes.

You will either have to use javascript or ajax for this. If you don’t  
know about them then start with google.

Colin
