<html>
<body>
<h3>A demonstration of how to access a Time field</h3>
<input type="time" id="myTime" value="22:15:00">
<p>Click the button to get the time of the time field.</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
function myFunction() {
var x = document.getElementById("myTime").value;
document.getElementById("demo").innerHTML = x;
}
</script>
</body>
</html>