Retro Digital - MeggiTools
Run
Toggle Theme
Share Link
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Retro Digital</title> <style> body { display: flex; justify-content: center; align-items: center; height: 100vh; background: #282828; margin: 0; font-family: 'Orbitron', sans-serif; color: #00ffcc; } .time-container { text-align: center; border: 5px solid #00ffcc; padding: 20px; border-radius: 10px; background: #000; box-shadow: 0 0 10px #00ffcc; } .time { font-size: 5em; } .date { font-size: 1.5em; margin-top: 10px; } </style> </head> <body> <div class="time-container"> <div class="time" id="time">--:--:--</div> <div class="date" id="date">Loading date...</div> </div> <script> function updateTime() { const timeElement = document.getElementById('time'); const dateElement = document.getElementById('date'); const now = new Date(); const hours = now.getHours().toString().padStart(2, '0'); const minutes = now.getMinutes().toString().padStart(2, '0'); const seconds = now.getSeconds().toString().padStart(2, '0'); const day = now.toLocaleString('en-US', { weekday: 'long' }); const month = now.toLocaleString('en-US', { month: 'long' }); const date = now.getDate(); const year = now.getFullYear(); timeElement.textContent = `${hours}:${minutes}:${seconds}`; dateElement.textContent = `${day}, ${month} ${date}, ${year}`; } setInterval(updateTime, 1000); updateTime(); </script> </body> </html>