I am working on a project where I have 3 radio buttons and 3 different combo boxes in my HTML. I want to use JavaScript to enable/disable the combo boxes based on which radio button is selected. For example, when the G1 radio button is clicked, I want only the G1 combo box to be enabled and the others to be disabled. How can I achieve this functionality with JS?
<input type="radio" name="g1" value="g1"> G1
<input type="radio" name="g2" value="g2"> G2
<input type="radio" name="g3" value="g3"> G3
<select name="g1">
<option value="one">one</option>
<option value="two">two</option>
<option value="three">three</option>
<select name="g2">
<option value="one">one</option>
<option value="two">two</option>
<option value="three">three</option>
<select name="g3">
<option value="one">one</option>
<option value="two">two</option>
<option value="three">three</option>