Javascript examples for DOM HTML Element:Input Text
Hide TextBox in html
<html> <head></head> <body> <textarea id="myP">This is a textarea.</textarea> <button type="button" onclick="hide()">Hide content of textarea</button> <button type="button" onclick="show()">Show content of textarea</button> <script> function hide() {//from ww w . j av a 2s.c o m document.getElementById("myP").style.visibility = "hidden" } function show() { document.getElementById("myP").style.visibility = "visible" } </script> </body> </html>