title: Laravel Create range of date with Carbon Interval
body: <p>I want to get range of date for example:</p>
  
  <pre><code>$startDate = Carbon::now()-&gt;subWeek();
  $endDate = Carbon::now();
  $period = new DatePeriod($startDate, CarbonInterval::day(), $endDate);
  
  foreach ($period as $row) {
          $date = $row-&gt;format('Y-m-d');
          echo $date. ', &amp;nbsp;';
  
  }
  </code></pre>
  
  <p>Those code will return me this date:</p>
  
  <pre><code>2016-04-24,  2016-04-25,  2016-04-26,  2016-04-27, ... until 2016-05-23
  </code></pre>
  
  <p>But the problem is, the date not return today's date (2016-05-24).</p>
  
  <p>How can I get today date using above code?</p>
  
  <p>Thanks.</p>
  
  <hr>
  
  <p>I can get today date buy changing <code>$endDate = Carbon::now();</code> to <code>$endDate = Carbon::now()-&gt;tomorrow();</code></p>
  
  <p>But its a little bit odd when read the code.</p>