Answers for "get date in format"

12

javascript date today dd mm yyyy

var today = new Date();
var dd = String(today.getDate()).padStart(2, '0');
var mm = String(today.getMonth() + 1).padStart(2, '0'); //January is 0!
var yyyy = today.getFullYear();

today = mm + '/' + dd + '/' + yyyy;
document.write(today);
Posted by: Guest on February-27-2020
4

powershell get date

Get-Date

Tuesday, June 25, 2019 14:53:32
Posted by: Guest on March-23-2020
0

get date in format

// GET THE CURRENT TIME............
const date = new Date();
var year = date.getUTCFullYear();
var month = (date.getUTCMonth()).toString.length == 2 ? date.getUTCMonth(): '0'+ date.getUTCMonth() ;
var day = (date.getUTCDay()).toString.length == 2 ? date.getUTCDay(): '0'+ date.getUTCDay() ;
var hours = date.getUTCHours();
var minutes = date.getUTCMinutes();
exDate = 'beckup_'+ year + '-' + month + '-' + day + '-' + hours + '-' + minutes ;
Posted by: Guest on June-15-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language