This question already has an answer here:
I want to print dates between 2 different dates (i.e. start date and two dates)
If start date is
2013-09-05 and end date is
2013-09-10, then I want result as
2013-09-05 2013-09-06 2013-09-07 2013-09-08 2013-09-09 2013-09-10
During month end and month start, it should print correct dates.