how can I get this format in as3?
YYYY-MM-DD , HH:MM:SS
Here is what I have put together however it doesnt give me right day.
public function getDate(e:Event):void {
var date:Date = new Date();
var yr = date.getFullYear();
var mnth = date.getMonth()+1;
var day = date.getDay();
var hr:int = date.getHours();
var mn:int = date.getMinutes();
var time:String = hr+":"+mn;
trace(yr+"-"+mnth+"-"+day+" "+time);
Instead it gives me a single for day of week it is, How can I get the actual day number so today is the 12th 2008-5-12 for example?