View Full Version : Select either radio button or the checkboxes

12-14-2004, 04:08 PM
Hi experts,
I have this form where it has one radio button and four checkboxes. Can someone help me to write a function where the form functionality is like radio buttons. If a user select the radio button, then the checkboxes should be uncheck and if the user selects any of the checkboxes then the radio button should be unselected automatically. Its more or less radio button functionality but combined with checkboxes. Users are allowed to select as much checkboxes as they want but at that time radio button must be unselected and vice-versa.

Thanks Mac

Willy Duitt
12-14-2004, 05:10 PM
Use an onclick event handler and target your form elements and use disabled=(true/false).... In the case of the checkboxes you will probably need a to use a loop and check which have been checked and set those to disabled=false.... While the single radio button could be referenced by its name....


12-14-2004, 05:49 PM
Do a forum seach for check all, or checkboxes, the same idea has be discussed before, look here (http://www.codingforums.com/showthread.php?t=48684&highlight=check) this should give you some idea.