forked from SuriyaaVijay/code-dump
-
Notifications
You must be signed in to change notification settings - Fork 0
/
umesh3
73 lines (60 loc) · 2.36 KB
/
umesh3
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="style.css" rel="stylesheet" type="text/css">
<title>Document</title>
</head>
<body>
<div class="container">
<img src="logo.png" class="logo">
<div class="content">
<p>Website is under mantainance</p>
<h1>We are<span> Launching </span> Soon</h1>
<div class="launch-time">
<div>
<p id="days">00</p>
<span>Days</span>
</div>
<div>
<p id="hours">00</p>
<span>Hours</span>
</div>
<div>
<p id="minutes">00</p>
<span>Minutes</span>
</div>
<div>
<p id="seconds">00</p>
<span>Seconds</span>
</div>
</div>
<button type="button">Explore more <img src="triangle.png"></button>
</div>
<img src="rocket.png" class="rocket">
</div>
<script>
var countDownDate = new Date("Oct 28 ,2023 00:00:00").getTime();
var x = setInterval(function () {
var now = new Date().getTime();
var distance = countDownDate - now;
var days = Math.floor(distance / (1000 * 60 * 60 * 24));
var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
var seconds = Math.floor((distance % (1000 * 60)) / 1000);
document.getElementById("days").innerHTML=days;
document.getElementById("hours").innerHTML=hours;
document.getElementById("minutes").innerHTML=minutes;
document.getElementById("seconds").innerHTML=seconds;
if(distance<0){
clearInterval(x)
document.getElementById("days").innerHTML="00";
document.getElementById("hours").innerHTML="00";
document.getElementById("minutes").innerHTML="00";
document.getElementById("seconds").innerHTML="00";
}
}, 1000);
</script>
</body>
</html>