You are here: irt.org | FAQ | JavaScript | Form | 3.1 | Q162 [ previous next ]
<form name="myFormName"> <input type="text" name="myFormFieldName"> </form> <script language="JavaScript"><!-- //setting the value: document.myFormName.myFormFieldName.value = "123abc"; //getting the value: var myVariableName = document.myFormName.myFormFieldName.value; //--></script>
This may not work with password form fields.