title: Need to validate MM/dd/yyyy hh:mm tt in Javascript
body: <p>I need to validate a date string in a specific format in Javascript.</p>
  
  <p>The format is: MM/dd/yyyy hh:mm tt</p>
  
  <p>I'm having a really hard time trying to find either a date library that will handle it, or a regex function that will do the same.</p>
  
  <p>I've tried Date.js, which is close, but has the following problem:</p>
  
  <pre><code>date.parseExact('10/21/2011 06:00 AM', ['MM/dd/yyyy hh:mm tt']); //passes
  date.parseExact('10/21/2011 06:00 A', ['MM/dd/yyyy hh:mm tt']); //passes
  </code></pre>
  
  <p>That second one should not pass.</p>
  
  <p>Does anyone know of a Regex that could satisfy this need, or perhaps am I using the Date.js library wrong?  Any help would be appreciated, I've been banging my head against the wall for the better part of 2 hours.</p>