Edit This Code:
<!DOCTYPE html>
<html>
<body>

Time: <input type="time" id="myTime">

<p>Click the button to set a time for the time field.</p>

<button onclick="myFunction()">Try it</button>

<p id="demo"></p>

<script>
function myFunction() {
    document.getElementById("myTime").value = "22:53:05";
}
</script>

</body>
</html>


Result:
Try it Yourself - © w3schools.com