Fix whitespace

This commit is contained in:
Remi Rampin 2021-01-25 12:49:03 -05:00
parent db8f217dff
commit e9e5474424
2 changed files with 72 additions and 62 deletions

49
fr.html
View File

@ -51,30 +51,41 @@
// Update the count down every 1 second
var x = setInterval(function() {
// Get today's date and time
var now = new Date().getTime();
// Get today's date and time
var now = new Date().getTime();
// Find the distance between now and the count down date
var distance = countDownDate - now;
// Find the distance between now and the count down date
var distance = countDownDate - now;
// Time calculations for days, hours, minutes and seconds
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);
// Time calculations for days, hours, minutes and seconds
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);
// Get today's date and time
var now = new Date().getTime();
// Output the result in an element with id="clock"
document.getElementById("day").innerHTML = days + " JOURS";
document.getElementById("hour").innerHTML = hours + " HEURES";
document.getElementById("min").innerHTML = minutes + " MINUTES";
document.getElementById("sec").innerHTML = seconds + " SECONDES";
// Find the distance between now and the count down date
var distance = countDownDate - now;
// If the count down is over, write some text
if (distance < 0) {
clearInterval(x);
document.getElementById("clock").innerHTML = "The wedding will start ASAP!";
}
// Time calculations for days, hours, minutes and seconds
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);
// Output the result in an element with id="clock"
document.getElementById("day").innerHTML = days + " JOURS";
document.getElementById("hour").innerHTML = hours + " HEURES";
document.getElementById("min").innerHTML = minutes + " MINUTES";
document.getElementById("sec").innerHTML = seconds + " SECONDES";
// If the count down is over, write some text
if (distance < 0) {
clearInterval(x);
document.getElementById("clock").innerHTML = "The wedding will start ASAP!";
}
}, 1000);
</script>
</html>

View File

@ -50,30 +50,29 @@
// Update the count down every 1 second
var x = setInterval(function() {
// Get today's date and time
var now = new Date().getTime();
// Get today's date and time
var now = new Date().getTime();
// Find the distance between now and the count down date
var distance = countDownDate - now;
// Find the distance between now and the count down date
var distance = countDownDate - now;
// Time calculations for days, hours, minutes and seconds
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);
// Time calculations for days, hours, minutes and seconds
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);
// Output the result in an element with id="clock"
document.getElementById("day").innerHTML = days + " DAYS";
document.getElementById("hour").innerHTML = hours + " HOURS";
document.getElementById("min").innerHTML = minutes + " MINUTES";
document.getElementById("sec").innerHTML = seconds + " SECONDS";
// Output the result in an element with id="clock"
document.getElementById("day").innerHTML = days + " DAYS";
document.getElementById("hour").innerHTML = hours + " HOURS";
document.getElementById("min").innerHTML = minutes + " MINUTES";
document.getElementById("sec").innerHTML = seconds + " SECONDS";
// If the count down is over, write some text
if (distance < 0) {
clearInterval(x);
document.getElementById("clock").innerHTML = "The wedding will start ASAP!";
}
// If the count down is over, write some text
if (distance < 0) {
clearInterval(x);
document.getElementById("clock").innerHTML = "The wedding will start ASAP!";
}
}, 1000);
</script>
</html>