PDA

View Full Version : Resetting radio buttons with a check box



dude9er
04-24-2006, 10:53 PM
I have three radio buttons, and they are all set to unchecked. If the user selects one, is there a way of resetting them back to unselected?

Here is the breakdown.

1. 3 radioBTNs are unselected
2. user clicks on one and selects it
3. the user then selects a CHECKBOX in the same form while will then reset ALL 3 radioBTNs

Is it possible?

THANKS

mwinter
04-24-2006, 11:26 PM
I have three radio buttons, and they are all set to unchecked.One should always be selected by default.


If the user selects one, is there a way of resetting them back to unselected?Yes, but why would you want to do that. What purpose does it serve?

Mike

dude9er
04-24-2006, 11:36 PM
i am using div tags to reveal and hide certain elements of a form depending on what the user chooses. if they change there mind on one section of the form then it would reset the radio buttons so that i am not receiving input from those fields.

mwinter
04-25-2006, 04:23 PM
i am using div tags to reveal and hide certain elements of a form depending on what the user chooses. if they change there mind on one section of the form then it would reset the radio buttons so that i am not receiving input from those fields.Then consider checking those values server-side only if the received state of the checkbox suggests that you should.

This sort of thing should be based around logic, not trickery. For a start, it's useless when client-side scripting is disabled (or someone decides to be naughty and bypasses those checks).

Mike