Welcome to the RuneGlory Wiki, where we do our best to make your life easier!

You can use the search menu on the right side of the wiki (or at the bottom if you are on mobile) to search for the page you are looking for. The most popular pages can be found on the right side of the wiki aswell (or again at the bottom if you are on mobile).

Difference between revisions of "Tournament"

From RuneGlory
Jump to: navigation, search
m (Protected "Dannyx Test3" ([Edit=Allow only administrators] (indefinite) [Move=Allow only administrators] (indefinite)) [cascading])
Line 1: Line 1:
 
<html>
 
<head>
 
<meta name="viewport" content="width=device-width, initial-scale=1">
 
  
 
</head>
 
</head>
Line 11: Line 7:
 
<script>
 
<script>
 
// Set the date we're counting down to
 
// Set the date we're counting down to
var countDownDate = new Date("Sep 5, 2018 15:37:25").getTime();
+
var countDownDate = new Date("Sep 5, 2018 15:37:25 GMT+0500").getTime();
 
 
 
// Update the count down every 1 second
 
// Update the count down every 1 second
 
var x = setInterval(function() {
 
var x = setInterval(function() {

Revision as of 02:27, 14 June 2018

</head> <body>

<script> // Set the date we're counting down to var countDownDate = new Date("Sep 5, 2018 15:37:25 GMT+0500").getTime(); // Update the count down every 1 second var x = setInterval(function() {

   // Get todays date and time
   var now = new Date().getTime();
   
   // Find the distance between now an 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);
   
   // Output the result in an element with id="demo"
   document.getElementById("demo").innerHTML = days + "d " + hours + "h "
   + minutes + "m " + seconds + "s ";
   
   // If the count down is over, write some text 
   if (distance < 0) {
       clearInterval(x);
       document.getElementById("demo").innerHTML = "EXPIRED";
   }

}, 1000); </script>

</body> </html>