title: JS for loop only checks first radio button
body: <p>why my loop only checks first radio button, and if I select 2nd or third it doesn't work?</p>
  
  <pre><code>function checkit(){
          for(var i=0;i&lt;document.forms[0].test.length;i++){
              if(document.forms[0].test[i].checked === true){
                  alert('OK');
                  break;
              }else { alert('hmz'); break; }
          }
      }
  
  &lt;form onsubmit="checkit();"&gt;
      First: &lt;input type="radio" name="test"&gt;&lt;br&gt;
      Second: &lt;input type="radio" name="test"&gt;&lt;br&gt;
      Third: &lt;input type="radio" name="test"&gt;&lt;br&gt;
      &lt;input type="submit" value="Lets try it!"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>Thank your for reply's. As noted, I have to take off break. But than another problem occurs, every time I press submit if any box is selected it gives me 3 alert box's. How to stop it? </p>