HTML Editor
<!DOCTYPE html> <html lang="en-US"> <body> <p>Click the button to display the UTC day of the current date.</p> <button onclick="myFunction()">Display UTC Day</button> <p id="point"></p> <p><strong>Note</strong>: 0 = Sunday, 6 = Saturday</p> <script> function myFunction() { var d = new Date(); var n = d.getUTCDay(); document.getElementById("point").innerHTML = n; } </script> </body> </html>
OUTPUT
×

Save as Private