Javascript examples for DOM HTML Element:Input Text
Disable a textbox by set its disabled attribute
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript"> window.onload=function(){/* w ww. j av a 2 s . c om*/ document.getElementById('freq2').setAttribute('disabled', true); } </script> </head> <body> <select id="freq2"> <option>Choose an option</option> </select> </body> </html>