SHARE
TWEET

Untitled

a guest Jun 25th, 2019 53 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var deadline = new Date("Apr 12, 2020 00:00:00").getTime();
  2. var x = setInterval(function() {
  3. var now = new Date().getTime();
  4. var t = deadline - now;
  5. var days = Math.floor(t / (1000 * 60 * 60 * 24));
  6. var hours = Math.floor((t%(1000 * 60 * 60 * 24))/(1000 * 60 * 60));
  7. var minutes = Math.floor((t % (1000 * 60 * 60)) / (1000 * 60));
  8. var seconds = Math.floor((t % (1000 * 60)) / 1000);
  9. document.getElementById("wielkanoc").innerHTML = days + "dni "  
  10. + hours + "godzin " + minutes + "minut " + seconds + "sekund ";
  11.     if (t < 0) {
  12.         clearInterval(x);
  13.         document.getElementById("wielkanoc").innerHTML = "EXPIRED";
  14.     }
  15. }, 1000);
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