1var today = new Date();
2var dd = String(today.getDate()).padStart(2, '0');
3var mm = String(today.getMonth() + 1).padStart(2, '0'); //January is 0!
4var yyyy = today.getFullYear();
5
6today = mm + '/' + dd + '/' + yyyy;
7document.write(today);
1// GET THE CURRENT TIME............
2const date = new Date();
3var year = date.getUTCFullYear();
4var month = (date.getUTCMonth()).toString.length == 2 ? date.getUTCMonth(): '0'+ date.getUTCMonth() ;
5var day = (date.getUTCDay()).toString.length == 2 ? date.getUTCDay(): '0'+ date.getUTCDay() ;
6var hours = date.getUTCHours();
7var minutes = date.getUTCMinutes();
8exDate = 'beckup_'+ year + '-' + month + '-' + day + '-' + hours + '-' + minutes ;