Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ** in javascript file
- function onTypeChange()
- {
- alert($('type_id').selectedIndex);
- if ($('type_id').selectedIndex != 0)
- {
- Element.update('chosenType', this.options[this.selectedIndex].text);
- Form.Element.enable('go_button');
- } else {
- Element.update('chosenType', 'Selected Type');
- Form.Element.disable('go_button');
- }
- }
- ** in html
- <select class="hosp_select_buttons selectbox" id="type_id" name="type[id]"
- onchange="onTypeChange();">
- <option value="">Please select</option>
- <option value="1594">Ambulatory Surgical Center</option>
- <option value="1595">Birthing Center</option>
- <option value="1596">Comprehensive Outpatient Rehabilitation Facilities</option>
- <option value="1597">Drug Abuse Treatment Program</option>
- <option value="1598">Mammography</option>
- <option value="1599">Narcotic Treatment Program</option>
- <option value="1600">Outpatient Physical Therapy</option>
- <option value="1601">Private Home Care Provider</option></select>
Add Comment
Please, Sign In to add comment