function getFormattedDate(formatedDate) {
var year = formatedDate.getFullYear();
var month = (1 + formatedDate.getMonth()).toString();
month = month.length > 1 ? month : '0' + month;
var day = formatedDate.getDate().toString();
day = day.length > 1 ? day : '0' + day;
return month + '/' + day + '/' + year;
}
var year = formatedDate.getFullYear();
var month = (1 + formatedDate.getMonth()).toString();
month = month.length > 1 ? month : '0' + month;
var day = formatedDate.getDate().toString();
day = day.length > 1 ? day : '0' + day;
return month + '/' + day + '/' + year;
}
No comments:
Post a Comment