Im trying to set a date time using new Date(<dateTime>)
, but the behaviour is different in chrome and IE/Firefox.
Works fine for IE/Firefox but not for chrome:
var date = new Date("2015-08-20T11:54");
Works fine in Chrome but not in IE/Firefox:
var date = new Date("2015-08-20 11:54 am");
My questions:
- What is the fundamental difference? is
Date()
implementation different in Chrome, IE/Firefox? - Is there a time format that is accepted by all the browsers when i use new
Date()
>