Theres lots of questions about how to convert a timestamp to yyyy-mm-dd but I am trying to do it the other way around.
I have an array of dates in the format 2013-02-25 but I want them to be js timestamps.
I have an array of dates such as ["2013-02-25", "2013-02-22", "2013-02-21"]
and ive tried
new Date(dateArray[0]).getTime() / 1000;
but this gives the wrong result as "2013-02-25" is converted to 1361750400 which is Fri, 16 Jan 1970 18:15:50 GMT
any suggestions on how to do this in javascript please?