<html> <body> <form name="myForm"> The form's name is: <input type="text" name="text1" size="20"> <br> <br> <input type="button" value="Show the form's name" onClick="this.form.text1.value=this.form.name"> </form> </body> </html>