471,594 Members | 2,401 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,594 software developers and data experts.

radio buttons and the onChange event handler

Hmmm... the onChange handler for radio buttons only seems to work when I
click on the specific radio button. If I cause it to change - become
unchecked - by clciking on another radio button in the group the handler
doesn't get called. Is this the way it's supposed to work?

I want to set optional properties of certain questions depending upon
whether radion button (a) is clicked or not. Is there some other event I
could set the handler for?

Thanks.
Jul 20 '05 #1
1 25296
Bill wrote:
Hmmm... the onChange handler for radio buttons only seems to work when I
click on the specific radio button. If I cause it to change - become
unchecked - by clciking on another radio button in the group the handler
doesn't get called. Is this the way it's supposed to work?
Yes, indeed. I think because checking if there is another radio button that
gets unchecked slows down processing, it is not implemented this way.
I want to set optional properties of certain questions depending upon
whether radion button (a) is clicked or not. Is there some other event I
could set the handler for?


You could use the `onchange' handler of the `form' element, or enclose
the radio buttons in a `fieldset' element and use its `onchange' handler.
HTH

PointedEars

Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Owen Funkhouser | last post: by
1 post views Thread by Robin Becker | last post: by
5 posts views Thread by Digital Puer | last post: by
2 posts views Thread by Peted | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.