Page 1 of 1

Setting radio button to checked if another is checked

Posted: Thu Aug 12, 2004 12:44 pm
by voltrader
I have a form with two sets of radio buttons, group1 and group2.

On a check of a button in group2, I would like a certain radio button in group1 to be automatically checked.

To get option1 button in group1 to be automatically checked upon a check of option1 button in group2, can I do this?

<input type='radio' name='group2' value='option1' onclick="document.group1.radio1.checked=true;">

Posted: Thu Aug 12, 2004 1:04 pm
by hawleyjr

SOLVED

Posted: Thu Aug 12, 2004 1:17 pm
by voltrader
excellent -- thanks.

onclick="document.formname.group[0].checked=true" did the job.