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

Popular posts from this blog

twig - Using Twigbridge in a Laravel 5.1 Package -

jdbc - Not able to establish database connection in eclipse -

firemonkey - How do I make a beep sound in Android using Delphi and the API? -