jQuery adding days to a date
<p>I am trying to add a number of days to a date selector input to get a start date and end date. I am getting an incorrect end date and cant see why.</p>

<p>Example: Date selected 25-10-2011, days 1</p>

<p>Result: date_start 2011-9-25, date_end 2012-5-7</p>

<pre><code> function makeUpDates(){
      // concantenate values to date_start and date_end hidden inputs
      var dateString = document.getElementById('date').value,
      date = new Date(dateString);
      document.getElementById('date_start').value = date.getFullYear() + '-' + date.getMonth() + '-' + date.getDate();

      var numDays = document.getElementById('slider').value;
      date.setDate(date.getDate() + numDays);   
      var dateEnd = date.getFullYear() + '-' + date.getMonth() + '-' + date.getDate();
      document.getElementById('date_end').value = dateEnd;
 }
</code></pre>
