Get your own website Result Size: 625 x 565
x
 
<!DOCTYPE html>
<html>
<body>
<input type="month" id="myMonth">
<p>Click the button to return which type of form element the month field is.</p>
<button onclick="myFunction()">Try it</button>
<p><strong>Note:</strong> The type property is not supported by Firefox.</p>
<p id="demo"></p>
<script>
function myFunction() {
  var x = document.getElementById("myMonth").type;
  document.getElementById("demo").innerHTML = x;
}
</script>
</body>
</html>