1.1 HTML Forms Flashcards
What is the HTML tag for the forms element?

How many form HTML tags can you use?
Only 1.
The proper HTML syntax is 1 form tag, per form.
You cannot nest form tags within a form.
What is the relationship between the form and the database?
Forms capture information from end users then send the information to a database.
In the database is where the information from the form is stored for use and retrieval later on.
What is the action attribute of a form do?
The action attribute is the web address where information is processed, submitted via form.
What are the two key attributes that forms need to process information?
- Action and
- Method
What does the method attribute of the form do?
Method is how it submits the form.
Methods can be either ___ or ___
Post or Get
What is the post method for forms?
Data from the form is posted to the server
What is the get method for forms?
Data is sent in the URL Parameters are separated using ? marks
Is there a backend component to forms?
Yes It is important to work with backend developer to make sure these pieces are “talking” and setup correctly.
What is the complete HTML syntax for form action with a post method? (ie. tags, signs, text, etc.)
The HTML is

When it comes to forms, how frequently used is the input element?
The input element is one of the most common elements used in forms.
What is a self closing HTML element?
It is an HTML element that doesn’t require a closing HTML tag.
Is the HTML input form element self-closing?
Yes, input is a self-closing HTML tag.
What is the text input field of a form?
It accepts text, numbers, even passwords.
What is the basic HTML syntax of a text field?
The text field HTML is Since it’s an input, it’s a self closing tag.
What types of inputs use numbers in a form?
Phone numbers, month, date
What 3 type of inputs would you collect from a form that relate to form organization to select choices?
Check boxes, radio buttons, drop down menus
What input types would control a form?
Reset, submit, button
What input types would you want from an end user?
Email, Password, Telephone number, URL
When would you want to use the input?
If you have a few sentences, then it’s best to use a form field.
What are the practical applications of the input area?
For writing a message in a form For asking users to write a bio For a quiz to allow several lines of text for writing
What does the type attribute do within the text field?
Type lets you specify the type of input it is (image, text, phone numbers, passwords, etc.)
What’s the HTML syntax for an input type with the the input type, id, and name? Include all relevant syntax elements

What does the name attribute do within a text field?
The name attribute helps process values data accordingly (user_(id)).
What is the HTML syntax for the password form field? Include syntax all elements

What’s the HTML syntax for an input type where you want a text area to appear?

What in the HTML syntax for the email form field? Include syntax elements like:

In what 5-6 scenarios would you want to use on a form?
for a comment on a review for feedback form for an intake form for a lead gen screening form for a project scope form for a message field on a contact us form
What is the HTML element field meant for in the context of a form?
The HTML element represents a multi-line plain-text editing control
Is rigid or flexible in number of lines of text?
is useful when you want to allow users to enter a sizeable amount of free-form text
In what 5-6 scenarios would you want to use on a form?
for a comment on a review for feedback form for an intake form for a lead gen screening form for a project scope form for a message field on a contact us form
What does the submit button do in relation to the server?
The submit button sends the information to the server where the filled form fields will reside until it’s needed.
What is the HTML syntax to submit a button? Include syntax elements like:

Does the button element require an opening and closing tag?
Yes, Buttons do require open and closing tag
What input type is used for buttons?
The input type for buttons is submit because you want the form to submit information to the database.
What’s the difference between a and ? (ie. Q & A format)
is the main container is a label within the main container
What does “reset” button do?
Reset clears all fields in a form.
What purpose does a fieldset serve on a form?
The HTML element is used to group several controls, labels, and fields into a section.
What’s the difference between a fieldset and legend?
fieldset is the main container is a label within the main container

What is a practical example of using legend tag?
You can use form legends to organize forms:
- define categories
- create sections
In the form, in project 3, there were two parts, how was legend HTML tag used to sub-divide the form?
The first legend grouped together the user contact information.
The second legend grouped together their subscription email preferences.

What’s the HTML syntax for a form button?

What is the HTML syntax for a drop down menu using the select tag?

Which HTML tag do you use to create drop down menus?
Select tag

Does a drop down menu allow for multiple choices?
No.
The individual needs to choose a single option from a list of pre-defined choices
What html tag do you use to specify a
pre-defined choice within a drop down menu?
Using the option tag you specify the value and text that goes with

How does the value work with the database where the form info is stored?
The value helps the database organize the information by creating categories of data.

Do radio buttons display all options available?
Yes, all choices are displayed with radio buttons.
Unlike drop down menus, which only show 1 default value, radio buttons typically display your choices upfront.
When is it ideal to use radio buttons?
When you have 5 or less choices to choose
from radio buttons are ideal.
What is the full HTML syntax for a radio button?

Does the for attribute need to match labels and IDs?
Yes.
To label an item correctly, the for attribute needs to match.

Are checkboxes suitable for more than 1 choice?
Yes, checkboxes are one way to have
multiple choices selected by the end user.
What input type do you use to create a checkbox in a form?
Checkbox

When writing the HTML syntax for checkbox, what 3 properties do you need to use? (V.I.N.)
VIN is the acroynm to remember.
V: Value
I: ID
N: Name
What would be an example of using, all 3 attributes from VIN, to create a single checkbox?
