function formatDate(millinSeconds){ var date = new Date(millinSeconds); var monthArr = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Spt","Oct","Nov","Dec"); var suffix = new Array("st","nd","rd","th"); var mm2 = 12-1; var year = 2021; //年 var month = monthArr[mm2]; //月 var ddate = 28; //日 if(ddate % 10 < 1 || ddate % 10 > 3) { ddate = ddate + suffix[3]; }else if(ddate % 10 == 1) { ddate = ddate + suffix[0]; } else if(ddate % 10 == 2) { ddate = ddate + suffix[1]; }else { ddate = ddate + suffix[2]; } return ddate + " "+ month + " " + year; }
function formatDate(millinSeconds){ var date = new Date(millinSeconds); var monthArr = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Spt","Oct","Nov","Dec"); var suffix = new Array("st","nd","rd","th"); var mm2 = 12-1; var year = 2021; //年 var month = monthArr[mm2]; //月 var ddate = 28; //日 if(ddate % 10 < 1 || ddate % 10 > 3) { ddate = ddate + suffix[3]; }else if(ddate % 10 == 1) { ddate = ddate + suffix[0]; } else if(ddate % 10 == 2) { ddate = ddate + suffix[1]; }else { ddate = ddate + suffix[2]; } return ddate + " "+ month + " " + year; }
function formatDate(millinSeconds){ var date = new Date(millinSeconds); var monthArr = new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Spt","Oct","Nov","Dec"); var suffix = new Array("st","nd","rd","th"); var mm2 = 12-1; var year = 2021; //年 var month = monthArr[mm2]; //月 var ddate = 28; //日 if(ddate % 10 < 1 || ddate % 10 > 3) { ddate = ddate + suffix[3]; }else if(ddate % 10 == 1) { ddate = ddate + suffix[0]; } else if(ddate % 10 == 2) { ddate = ddate + suffix[1]; }else { ddate = ddate + suffix[2]; } return ddate + " "+ month + " " + year; }