Question Locked

Disabled value for text fields in an html form

0 helpful
3 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Hi Everyone

I have a radio button group in a form that is a sample A,B,C or
'Other" options. Below "Other" is a text field that is disabled by
default and only becomes enabled when you click the "Other" radio
button. Click any of the A, B, or C radio buttons disabled the text
area again. By default, Option A is selected. My problem is this, if
I click on "Other" when testing the form, it enables the text area,
which is fine, but if I then hit the reset button on the form, option
A is selected again, but the text area does not go back to being
disabled. Can anyone suggest why this might be happening?

Thanks for the help

3 replies

by thumbsup2

Are you using JavaScript to disable the text box? If so, do you have anything to reset the text box after the reset button is clicked?

by mahonc

Yes, I am using HTML/Javascript

I had though that having disabled="disabled" in the tag for the text field would be it's "initial value" and as such would apply when I reset. Is there a function/code I need to put in there to disable when I reset?
Thanks so much for the help!

This discussion is closed to new replies.