skip to Main Content

I’d like to make a clock/callendar like in this webpage.

https://uawar.net/stats

I do not know if this requires js in my html codes. But when I inspected the webpage the div-counter time, I was the ” and the time flashing in purple.

how do I make a clock/callendar just like that?

2

Answers


  1. Yes, you need both HTML and Javascript for your functions to run with real-time date and time.

    Here is an example:
    Then you need to add javascript functions for their updation.

    <!DOCTYPE html>
    <html>
    <head>
      <title>Countdown Timer</title>
      </head>
    <body>
    <div class="countdown">
            <span id="days">00</span>:
            <span id="hrs">00</span>:
            <span id="min">00</span>:
            <span id="sec">00</span>
       </div>
    Login or Signup to reply.
  2. you need a setInterval function to make the clock live

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search