Form Summary

In this lesson, we learned how to use forms and discovered that:

  • A form is created using the form element with the following attributes:
    • action, which specifies the URL where the form data will be sent.
    • method, which specifies the request method. Most commonly POST.
  • Inputs are created using the input element with the following attributes:
    • name - the name of the input.
    • id - the identifier of the input.
    • type - the type of the input.
  • Some example input types include:
    • password - for passwords
    • number - for numeric input
    • checkbox - for checkboxes
    • range - for selecting a value within a specific range
  • The description of an input is created using the label element, which has a for attribute with the same value as the id attribute of the corresponding input element.
  • Form submission is performed using the input element with the attribute type="submit" and the value attribute, which specifies the text to be displayed on the button.
  • To make an input required, we add the required attribute to the input.

Instructions

Congratulations on completing the HTML course! The editor contains your final code from this lesson. Now you can customize the page using your newly acquired knowledge.

Start programming for free

By signing up, you agree to the Terms of Service and Privacy Policy.

Or sign up with:

9/9

Form Summary | Start Coder