I have a string consisting of '2013-04-05T00:00:00'. When I embed the below code into my js file Chakra (IE javascript engine) barfs. When I run this from the IE console it barfs. Every other browser I have tested on is fine. How can i make the below statement browser agnostic?
var targetDate = new Date('2013-04-05T00:00:00');
alert(targetDate);
EDIT
IE version 7,8 does not run
runs fine in ie 9+
EDIT#2
The reason this doesn't work is that IE 8,7 do not support ISO date times. You will either need to generate a Date object from a non ISO date time stamp.