Text.value : Text Object : Form JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Form » Text Object »

 

Text.value







The value property returns the current value of the text box.












<html>
    <head>
    <script language="JavaScript">
    <!--
    function resetText(){
      document.myForm.myText.value = document.myForm.myText.defaultValue;
    }
    -->
    </script>
    </head>
    <body>
    <form name="myForm">
      <input type=TEXT value="First Box" name="myText">
      <input type=BUTTON value="Reset" name="myButton" onClick='resetText()'>
    </form>
    </body>
    </html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Form
» Text Object