new javascript Date from a string and formatting template?
<p>I have an application that works in several "cultures".  I will be using many date formats.</p>

<p>I have a string with my format (i.e. 'd/m/y', but keep in mind this is variable) and 2 text inputs with dates in that given format.</p>

<p>I need to compare the dates in input box 1 to input box 2.  I had a method that did this fine, until we added the international formatting.</p>

<pre><code>new Date(endDate) &gt;= new Date(startDate)
</code></pre>

<p>This used to work with U.S. only dates.  It does not now.  Is there a method I can use that works like this?:</p>

<pre><code>new Date(endDate, 'd/m/y')
</code></pre>
