SHARE
TWEET

function getData ()

EvaldoMaciel May 25th, 2020 863 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function getData () {
  2.     var data = new Date();
  3.     var dia  = data.getDate();
  4.     var mes  = data.getMonth() + 1;
  5.     var ano  = data.getFullYear();
  6.     dia  = (dia<=9 ? "0"+dia : dia);
  7.     mes  = (mes<=9 ? "0"+mes : mes);
  8.     var novaData = ano+"/"+mes+"/"+dia;
  9.     return novaData;
  10. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top