Canlı saat (JavaScript)

1. Kazimli Anar Вчера / 21:20
📌 Mövzu: “Sayta canlı saat əlavə et”

<div id="clock"></div>

<script>
function updateClock(){
    let now = new Date();
    document.getElementById("clock").innerHTML =
        now.getHours() + ":" + now.getMinutes() + ":" + now.getSeconds();
}
setInterval(updateClock, 1000);
</script>


URL: https://mywap.az/topics/5