title: How to compare two dates (MonthName YearNumber) in javascript
body: <p>This functionality is working fine in Chrome... But not IE or FF.</p>
  <p>I am trying to validate two fields that take the value of MonthName YearNumber (see screenshot).</p>
  <p><a href="https://i.stack.imgur.com/eXqYx.gif" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/eXqYx.gif" alt="form" /></a></p>
  
  <p>I am using <code>Date.parse()</code> to get miliseconds, then compare if <code>Start Date</code> &lt;= <code>End Date</code>.</p>
  <pre><code>function IsStartEndDtError(StartDt, EndDt) {
      //convert dates to miliseconds to compare if one is greater than other
      var StartDtMili = Date.parse(StartDt);
      var EndDtMili = Date.parse(EndDt);
  
      if (StartDtMili &lt;= EndDtMili) {
          return false;
      }
      else {
          return true;
      }
  }
  </code></pre>
  <p>What appears in Firebug:</p>
  <p><a href="https://i.stack.imgur.com/z7ATP.gif" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/z7ATP.gif" alt="form2" /></a></p>