AS3是否有办法将日期时间变量转换为本地时间?
答案 0 :(得分:3)
//Some date string you got from somewhere
var dateStr:String = "Sun Sep 25 22:30:33 GMT+0600 2011";
var date:Date = new Date(dateStr);
//Use date.toLocaleString() to get a local time string and create a new date from it
var localDate:Date = new Date(date.toLocaleString());
trace(localDate);'
这是Adobe的date.toLocaleString()链接