title: jQuery Validation engine, past and future date validation by dd/mm/yyyy format
body: <p>I am new in jQuery. I am using jQuery version 1.8.3. In my ASP.NET Web application, I am using jQuery Validation engine to validate date. I am dynamically creating HTML text input which allows user to enter date only in dd/mm/yyyy format and here I am assigning both past and future validators to texbox. I want to validate date in dd/mm/yyyy format by using past and future validators in such way that user should allow enter only the date between the value given to past and future. And If user enter date beyond given restriction it should show date in message in dd/mm/yyyy format too. </p>
  
  <p>But what happening is; past and future date validators validating only when I pass date in yyyy-mm-dd format and I have to enter date in textbox in yyyy-mm-dd format. </p>
  
  <p>Everyone opinions are welcome </p>
  
  <p>What I tried till now is as follows:</p>
  
  <pre><code>HtmlGenericControl l_oHGC = new HtmlGenericControl("div");
  divCustomFields.Controls.Add(l_oHGC);
  TextBox l_oTXT = new TextBox();
  l_oHGC.Controls.Add(l_oTXT);
  l_oTXT.Text = Convert.ToDateTime("Apr 16 2014 12:00AM").ToString(gc.APP_DATEFORMAT_DD_MM_YYYY);
  l_oTXT.MaxLength = 10;
  l_oTXT.CssClass = "calender validate[custom[date],past[" + Convert.ToDateTime("Dec 31 2050 12:00AM").ToString(gc.APP_DATEFORMAT_DD_MM_YYYY) + "],future[" + Convert.ToDateTime("Apr 26 2014 12:00AM").ToString(gc.APP_DATEFORMAT_DD_MM_YYYY) + "]]";
  </code></pre>
  
  <p><strong>In jquery.validationEngine-en.js I did following changes</strong></p>
  
  <pre><code> "past": {
      "regex": /^(0?[1-9]|[12][0-9]|3[01])[\/\-](0?[1-9]|1[012])[\/\-]\d{4}$/,
                  "alertText": "* Date prior to "
          },
    "future": {
       "regex": /^(0?[1-9]|[12][0-9]|3[01])[\/\-](0?[1-9]|1[012])[\/\-]\d{4}$/,
                  "alertText": "* Date past "
          },  
      "date": {
         "regex": /^(0?[1-9]|[12][0-9]|3[01])[\/\-](0?[1-9]|1[012])[\/\-]\d{4}$/,
                  "alertText": "* Invalid date, must be in DD/MM/YYYY format"
         },  
  </code></pre>