06.for(vard = from_date; d <= to_date; d.setDate(d.getDate() + 1)) {
07.document.write(newDate(d) + "<br>");
08.}
09.</script>
10.
11.</body>
12.</html>
Result
Sat Aug 1 00:00:00 UTC+0700 2015
Sun Aug 2 00:00:00 UTC+0700 2015
Mon Aug 3 00:00:00 UTC+0700 2015
Tue Aug 4 00:00:00 UTC+0700 2015
Wed Aug 5 00:00:00 UTC+0700 2015
Thu Aug 6 00:00:00 UTC+0700 2015
Fri Aug 7 00:00:00 UTC+0700 2015
Sat Aug 8 00:00:00 UTC+0700 2015
Sun Aug 9 00:00:00 UTC+0700 2015
Mon Aug 10 00:00:00 UTC+0700 2015
Tue Aug 11 00:00:00 UTC+0700 2015
Wed Aug 12 00:00:00 UTC+0700 2015
Thu Aug 13 00:00:00 UTC+0700 2015
Fri Aug 14 00:00:00 UTC+0700 2015
Sat Aug 15 00:00:00 UTC+0700 2015