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

Javascript examples for DOM HTML Element:Input URL

Description

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

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<body>
Homepage: <input type="url" id="myURL" disabled>

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

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

<script>
function myFunction() {//from  w w  w.  ja va 2  s  . c o m
    var x = document.getElementById("myURL").disabled;
    document.getElementById("demo").innerHTML = x;
}
</script>

</body>
</html>

Related Tutorials