Input Date disabled Property - Find out if a date field is disabled or not: - Javascript DOM HTML Element

Javascript examples for DOM HTML Element:Input Date

Description

Input Date disabled Property - Find out if a date field is disabled or not:

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<body>

<input type="date" id="myDate" disabled>

<button onclick="myFunction()">Test</button>

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

<script>
function myFunction() {//from   www .ja  va2s . c om
    var x = document.getElementById("myDate").disabled;
    document.getElementById("demo").innerHTML = x;
}
</script>

</body>
</html>

Related Tutorials