- <html>
- <head><title>myForm</title><head>
- <body>
- <form action = "example.com" method="Post">
- First Name:
- <input type = "text" name = "firstname" />
- Last Name:
- <input type = "text" name = "lastname" />
- <input type = "submit" value = "submit" />
- <input type = "text" value = "Reset" />
- </form>
- </body>
- </html>
The INPUT element defines an input field. When you specify "submit" (or "reset") for the type attribute of this element, a submit button (or a reset button) is created.
type = "submit" Creates a submit button on the form. When this button is clicked, the form data is submitted to the server.
type = "reset" Creates a reset button on the form. When this button is clicked, the input is reset.
name = "" The button name is used to identify the clicked submit button.
value = "" Value is the text displayed on the button.
No comments:
Post a Comment