# Ajax help

**URL:** <https://www.ruby-forum.com/t/ajax-help/146280>\
**Category:** Rails\
**Created:** [August 19, 2008, 6:53pm UTC](https://www.ruby-forum.com/t/ajax-help/146280 "2008-08-19T18:53:24Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![giga](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/b9bd4f/32.png) [@giga](https://www.ruby-forum.com/u/giga)\
**Post date:** [August 19, 2008, 6:53pm UTC](https://www.ruby-forum.com/t/ajax-help/146280/1 "2008-08-19T18:53:24Z")

</div>

1. How can I update option in -box with Ajax ?

2. How can I by clickin text-link update content of some

---

<div class="post-metadata">

**Author:** ![giga](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/b9bd4f/32.png) [@giga](https://www.ruby-forum.com/u/giga)\
**Post date:** [August 19, 2008, 9:13pm UTC](https://www.ruby-forum.com/t/ajax-help/146280/2 "2008-08-19T21:13:19Z")

</div>

On 19 Aug 2008, at 17:53, Gi Ga wrote:

> 1. How can I update option in -box with Ajax ?

You mean change the options in the select box ?

> 1. How can I by clickin text-link update content of some 
> ?
> 
> link\_to\_remote ‘click me’, :update =\> ‘some\_div’, :url =\> {:controller  
> =\> ‘foo’, :action =\>‘var’}
> 
> Fred

---

<div class="post-metadata">

**Author:** ![giga](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/b9bd4f/32.png) [@giga](https://www.ruby-forum.com/u/giga)\
**Post date:** [August 20, 2008, 9:32pm UTC](https://www.ruby-forum.com/t/ajax-help/146280/3 "2008-08-20T21:32:15Z")

</div>

Frederick C. wrote:

> > 1. How can I update option in -box with Ajax ?
> 
> You mean change the options in the select box ?

Yes, add / remove options in select box

> > 1. How can I by clickin text-link update content of some 
> > ?
> > 
> > link\_to\_remote ‘click me’, :update =\> ‘some\_div’, :url =\> {:controller  
> > =\> ‘foo’, :action =\>‘var’}
> > 
> > Thanks.

---

<div class="post-metadata">

**Author:** ![giga](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/b9bd4f/32.png) [@giga](https://www.ruby-forum.com/u/giga)\
**Post date:** [August 21, 2008, 12:42am UTC](https://www.ruby-forum.com/t/ajax-help/146280/4 "2008-08-21T00:42:54Z")

</div>

On Aug 20, 8:32 pm, Gi Ga [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Frederick C. wrote:
> 
> > > 1. How can I update option in -box with Ajax ?
> 
> > You mean change the options in the select box ?
> 
> Yes, add / remove options in select box

Well in theory you could just do an ajax update that updates the  
select box (ie where the action just renders the option tags).

Fred
