Hello, I am trying to make the text in an html text box disappear when the user clicks on it. Does anyone know how to do this? I'm guessing there would be some java script involved, but I am not sure. Also does anyone know how to disable a text box so the user cannot type into it? Thank You, Jason
copy this Java script in the HTML head <script language="Javascript"> <!-- function doClear(theText) { if (theText.value == theText.defaultValue) { theText.value = "" } } //--> </script> ================================= Please do this in your html body section : <form> <input type="text" size=15 value="Enter name" onFocus="doClear(this)"> </form>