Javascript return false not working
<p>Guys this code is returning false in a blank page after submit.What is the error of my code.</p>

<pre><code>function send_serial(){
    //Check date
    var date=document.getElementById('date_field').value;
    if(date==''||date==null){
    alert('Please select the date.');
        return false;
  }  

}
</code></pre>
