I have an HTML form that works in all browsers… [B]only if I comment out the radio buttons part
All I want to do with my radio buttons is this:
if (any radio button is selected) {
do this;
} else {
do that;
}
At this point, the radiobuttons part of my script works well in IE 6.0, whereas it is ignored in Firefox and Netscape.
Here is the script (just one part of it — the rest works perfectly in any browser, as I mentioned before):
[CODE]
document.getElementById(“range”).style.color = “#FF0000”;
myForm+=1;
for (var i=0; i<document.applForm.elements[“investment”].length; i++){
radio = document.applForm.elements[“investment”][i];
if (radio.checked == true) {
document.getElementById(“range”).style.color = “#000000”;
myForm-=1;
}
}
[code=html]
<td><input type=”radio” value=”Yes” name=”investment” ></td>
<td><input type=”radio” value=”No” name=”investment” </td>
I would appreciate any help.