title: Return false is not working AJAX
body: <p>I have got this in my index.htm</p>
  
  <pre><code>&lt;form&gt;
  &lt;input onkeyup="firstnamecheck(this.value)" type="text" name="firstname" id="Start" class="Inputs" /&gt;
  &lt;button type="submit" name="Murad"  id="tester"title="Register" &gt;Register&lt;/button&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>And this in reg.js</p>
  
  <pre><code>function firstnamecheck(str) {
      if (str.length == 0) { 
          document.getElementById("firster").innerHTML = "";
          return false;
      }else if(3&gt;str.length&gt;0){
          document.getElementById("firster").innerHTML = "Firstname should be more than 3 charachters";
          return false; 
      }else if(str.length&gt;30){
          document.getElementById("firster").innerHTML = "Firstname should be less than 30 charachters";
  
         return false; 
      } else {
          var xmlhttp = new XMLHttpRequest();
          xmlhttp.onreadystatechange = function() {
              if (xmlhttp.readyState == 4 &amp;&amp; xmlhttp.status == 200) {
                  document.getElementById("firster").innerHTML = xmlhttp.responseText;
              }
          };
          xmlhttp.open("POST", "era.php?f=" + str, true);
          xmlhttp.send();
      }
  }
  </code></pre>
  
  <p>But even when it gives error i can still submit form even though there is return false.</p>