I’ve been struggling with this for 2 days – I figure either I’m way out in left field or I’m missing something obvious. Please help!
I have an HTML form, and I’m using javascript to validate that a radio button has been selected. From the documentation I’ve read on WC3 and MSDN this code should work, but it doesn’t. What am I doing wrong?
HTML Snippet:
<DIV id=”oRadio”>
<p>Do you like radio buttons?
Yes <input type=”radio” name=”Radio Buttons” value=”Yes”>
Maybe <input type=”radio” name=”Radio Buttons” value=”Maybe” >
No <input type=”radio” name=”Radio Buttons” value=”No” ></p>
</div>
JavaScript Snippet:
var radioList = document.body.getElementsByTagName(“oRadio”);
Thanks in advance for your help!
Sherri