# Any way to add 'onchange' to a 'select' helper?

**URL:** <https://www.ruby-forum.com/t/any-way-to-add-onchange-to-a-select-helper/50882>\
**Category:** Rails\
**Created:** [December 22, 2005, 4:42am UTC](https://www.ruby-forum.com/t/any-way-to-add-onchange-to-a-select-helper/50882 "2005-12-22T04:42:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![df-sean](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/f07891/32.png) [@df-sean](https://www.ruby-forum.com/u/df-sean)\
**Post date:** [December 22, 2005, 4:42am UTC](https://www.ruby-forum.com/t/any-way-to-add-onchange-to-a-select-helper/50882/1 "2005-12-22T04:42:50Z")

</div>

I basically have a select menu with two options:  
– Leave password unchanged –  
– Enter new password below –

I want my form to use a sexy prototype effect to SlideDown the text  
field when the second option is selected. That way the user isn’t  
confused by a blank password field when they’ve selected to leave the  
password unchanged.

Can I do this with Rails’s ‘select’ helper? Is there something like  
‘:onchange =\> foobar’ that I can use? Or do I need to write out my own  
select tag for this?

Thanks! - Sean
