title: How to disable dates before today in jquery UI datepicker?
body: <p>I am making a hotel reservation system i have to disable past dates in jQuery UI datepicker 
  here's the code  </p>
  
  <p>calling in .cs</p>
  
  <pre><code>   public class CheckLookup
          {
              [DataType(DataType.Date)]
              public DateTime checkindate { get; set; }
              [DataType(DataType.Date)]
              public DateTime checkoutdate { get; set; }
          }
  </code></pre>
  
  <p>Here's the javascript </p>
  
  <pre><code> $(document).ready(function () {
          function getDateYymmdd(value) {
              if (value == null)
                  return null;
              return $.datepicker.parseDate("yy-mm-dd", value);
          }
          $('.date').each(function () {
              var minDdate = getDateYymmdd($(this).data(""));
              var maxDate = getDateYymmdd($(this).data("val-rangedate-max"));
              $(this).datepicker({
                  dateFormat: "dd-mm-yy", 
                  minDate: minDate,
                  maxDate: maxDate
              });
          });
      });
  </code></pre>
  
  <p>tell me the modification to be done in this code.</p>