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

E-mail: <input type="email" id="myEmail" readonly>

<p>Click the button to find out if the email field is read-only.</p>

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

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

<script>
function myFunction() {
    var x = document.getElementById("myEmail").readOnly;
    document.getElementById("demo").innerHTML = x;
}
</script>
</body>
</html>


Result:
Try it Yourself - © w3schools.com
Privacy Policy