Thursday, 23 April 2015

HTML Forms - Submit and Reset Button

  1. <html>
  2. <head><title>myForm</title><head>
  3. <body>
  4. <form action = "example.com" method="Post">
  5. First Name:
  6. <input type = "text" name = "firstname" />
  7. Last Name:
  8. <input type = "text" name = "lastname" />
  9. <input type = "submit" value = "submit" />
  10. <input type = "text" value = "Reset" />
  11. </form>
  12. </body>
  13. </html>
HTML Forms are required when you want to collect some data from the site visitor. HTML Forms are required when you want to collect some data from the site visitor. For example registration information: name, email address, credit card, etc. A form will take input from the site visitor and then will post your back-end application such as CGI, ASP Script or PHP script etc. Then your back-end application will do required processing on that data in whatever way you like. Form elements are like text fields, textarea fields, drop-down menus, radio buttons, checkboxes, etc. which are used to take information from the user.
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.


html HTML5 html forms  

For such more blogs you can visit to 
http://findnerd.com/NerdDigest/
                         

No comments:

Post a Comment