title: reset value after checking onchange value in select in jsp
body: <p>in here I would like to check  on change value in calendar then reset the old value.But it couldn't be.it checks the value in javascript function but after that it reset the new value.But i want old value there.Mainly it checks the select date whether before the set date, if yes give alert.But then it change to new value.i want old value again after the alert.</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  function check_from(a,b,c) {
      var date=Date.parse(a);
      var date2=Date.parse(b);
      var date3=Date.parse(c);
  
      if(date3&lt;date || date3&gt;date2){
          alert("Please select date betwen"+" "+a+" "+"and"+" "+b);
          return false;
      }       
  }
  &lt;/script&gt;
  
  &lt;input id="date_1" class="input-medium ndshaatepicker-basic" type="text" value=&lt;%=rs.getString("start_date")%&gt; onchange="check_from('&lt;%=rs.getString("start_date") %&gt;','&lt;%=rs.getString("end_date") %&gt;',this.value)"&gt;
  </code></pre>