Setting minimum date to date picked in previous datepicker
<p>I have two date pickers. A <code>startdate</code> and an <code>enddate</code>.</p>

<p>The way I have the code set up is that the second datepicker won't be initiated until the first one has been changed. The <code>enddate</code> datepicker is initialized with the current date on <code>startdate</code>. The only problem is that if you change the time on the first datepicker it doesn't refresh the <code>mindate</code> on <code>enddate</code>.</p>

<pre><code>   $(function(){
   $( "#startdate" ).datepicker({ minDate: currentTime });

        //When the startdate changes change the mindate for the enddate picker
        $( "#startdate" ).change(function (){
             startTime = ($("#startdate").val());
            $("#enddate").datepicker({ minDate: startTime });

       });

       //$( "#enddate" ).datepicker({ minDate: currentTime });
  });
</code></pre>
