Can someone explain this odd javascript date output? -
https://jsfiddle.net/8cvhnwgs/1/
//new date(year, month, day, hours, minutes, seconds, milliseconds) $("#out").html(new date(2015, 5, 31, 08, 25, 30, 0));
the date give may 31st, outputs july first, can explain why? have used arguments wrong?
the month
parameter date
constructor 0 indexed, 5 june, has 30 days.
Comments
Post a Comment