I am trying to convert milliseconds into a date that looks like: Oct 04, 2013
. I converted milliseconds into a date object with:
var d1 = new Date(milliseconds);
which then outputs something like:
Fri Oct 04 2013 13:59:31 GMT-0400 (Eastern Daylight Time)
If I use getMonth()
, getDate()
, and getFullYear()
the output becomes 9 4 2013
How do I get the month either a full name (October) or shortened to three characters (Oct)?