Hello team,
My company uses readymag for business proposals, and every single time, we do it we all wish you have a countdown timer.
Thank you.
Kirill (Kris)
CEO
Spinach Video
Hello team,
My company uses readymag for business proposals, and every single time, we do it we all wish you have a countdown timer.
Thank you.
Kirill (Kris)
CEO
Spinach Video
Hi @Kirill_Lucenko we used some custom code for a timer on a couple projects. See below.
Hopefully gives you a starting point!
<div id="timer">
<div id="days"></div>
<div id="hours"></div>
<div id="minutes"></div>
<div id="seconds"></div>
</div>
<style>
body {
overflow: hidden;
text-align: center;
font-size: 100px;
}
div {
display: inline-block;
padding: 0 10px;
min-width: 180px;
color: #B59963;
line-height: 1;
}
span {
display: block;
color: #575757;
text-transform: uppercase;
font-size: 30px;
}
@media only screen and (max-width: 600px) {
body {
font-size: 40px;
}
div {
min-width: auto;
padding: 0 10px;
}
span {
font-size: 10px;
}
}
</style>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<script>
function makeTimer() {
var endTime = new Date("20 August 2023 18:00:00 GMT-0:00");
endTime = (Date.parse(endTime) / 1000);
var now = new Date();
now = (Date.parse(now) / 1000);
var timeLeft = endTime - now;
var days = Math.floor(timeLeft / 86400);
var hours = Math.floor((timeLeft - (days * 86400)) / 3600);
var minutes = Math.floor((timeLeft - (days * 86400) - (hours * 3600)) / 60);
var seconds = Math.floor((timeLeft - (days * 86400) - (hours * 3600) - (minutes * 60)));
if (hours < "10") {
hours = "0" + hours;
}
if (minutes < "10") {
minutes = "0" + minutes;
}
if (seconds < "10") {
seconds = "0" + seconds;
}
$("#days").html(days + "<span>Days</span>");
$("#hours").html(hours + "<span>Hours</span>");
$("#minutes").html(minutes + "<span>Minutes</span>");
$("#seconds").html(seconds + "<span>Seconds</span>");
}
setInterval(function() {
makeTimer();
}, 1000);
</script>