1.1 HTML Forms Flashcards

1
Q

What is the HTML tag for the forms element?

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How many form HTML tags can you use?

A

Only 1.

The proper HTML syntax is 1 form tag, per form.

You cannot nest form tags within a form.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is the relationship between the form and the database?

A

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.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the action attribute of a form do?

A

The action attribute is the web address where information is processed, submitted via form.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What are the two key attributes that forms need to process information?

A
  1. Action and
  2. Method
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What does the method attribute of the form do?

A

Method is how it submits the form.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Methods can be either ___ or ___

A

Post or Get

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is the post method for forms?

A

Data from the form is posted to the server

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is the get method for forms?

A

Data is sent in the URL Parameters are separated using ? marks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Is there a backend component to forms?

A

Yes It is important to work with backend developer to make sure these pieces are “talking” and setup correctly.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the complete HTML syntax for form action with a post method? (ie. tags, signs, text, etc.)

A

The HTML is

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

When it comes to forms, how frequently used is the input element?

A

The input element is one of the most common elements used in forms.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What is a self closing HTML element?

A

It is an HTML element that doesn’t require a closing HTML tag.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Is the HTML input form element self-closing?

A

Yes, input is a self-closing HTML tag.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What is the text input field of a form?

A

It accepts text, numbers, even passwords.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is the basic HTML syntax of a text field?

A

The text field HTML is Since it’s an input, it’s a self closing tag.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What types of inputs use numbers in a form?

A

Phone numbers, month, date

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

What 3 type of inputs would you collect from a form that relate to form organization to select choices?

A

Check boxes, radio buttons, drop down menus

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

What input types would control a form?

A

Reset, submit, button

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

What input types would you want from an end user?

A

Email, Password, Telephone number, URL

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

When would you want to use the input?

A

If you have a few sentences, then it’s best to use a form field.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What are the practical applications of the input area?

A

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

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What does the type attribute do within the text field?

A

Type lets you specify the type of input it is (image, text, phone numbers, passwords, etc.)

24
Q

What’s the HTML syntax for an input type with the the input type, id, and name? Include all relevant syntax elements

A
25
Q

What does the name attribute do within a text field?

A

The name attribute helps process values data accordingly (user_(id)).

26
Q

What is the HTML syntax for the password form field? Include syntax all elements

A
27
Q

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

A
28
Q

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

A
29
Q

In what 5-6 scenarios would you want to use on a form?

A

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

30
Q

What is the HTML element field meant for in the context of a form?

A

The HTML element represents a multi-line plain-text editing control

31
Q

Is rigid or flexible in number of lines of text?

A

is useful when you want to allow users to enter a sizeable amount of free-form text

32
Q

In what 5-6 scenarios would you want to use on a form?

A

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

33
Q

What does the submit button do in relation to the server?

A

The submit button sends the information to the server where the filled form fields will reside until it’s needed.

34
Q

What is the HTML syntax to submit a button? Include syntax elements like:

A
35
Q

Does the button element require an opening and closing tag?

A

Yes, Buttons do require open and closing tag

36
Q

What input type is used for buttons?

A

The input type for buttons is submit because you want the form to submit information to the database.

37
Q

What’s the difference between a and ? (ie. Q & A format)

A

is the main container is a label within the main container

38
Q

What does “reset” button do?

A

Reset clears all fields in a form.

39
Q

What purpose does a fieldset serve on a form?

A

The HTML element is used to group several controls, labels, and fields into a section.

40
Q

What’s the difference between a fieldset and legend?

A

fieldset is the main container is a label within the main container

41
Q

What is a practical example of using legend tag?

A

You can use form legends to organize forms:

  • define categories
  • create sections
42
Q

In the form, in project 3, there were two parts, how was legend HTML tag used to sub-divide the form?

A

The first legend grouped together the user contact information.

The second legend grouped together their subscription email preferences.

43
Q

What’s the HTML syntax for a form button?

A
44
Q

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

A
45
Q

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

A

Select tag

46
Q

Does a drop down menu allow for multiple choices?

A

No.

The individual needs to choose a single option from a list of pre-defined choices

47
Q

What html tag do you use to specify a
pre-defined choice within a drop down menu?

A

Using the option tag you specify the value and text that goes with

48
Q

How does the value work with the database where the form info is stored?

A

The value helps the database organize the information by creating categories of data.

49
Q

Do radio buttons display all options available?

A

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.

50
Q

When is it ideal to use radio buttons?

A

When you have 5 or less choices to choose
from radio buttons are ideal.

51
Q

What is the full HTML syntax for a radio button?

A
52
Q

Does the for attribute need to match labels and IDs?

A

Yes.

To label an item correctly, the for attribute needs to match.

53
Q

Are checkboxes suitable for more than 1 choice?

A

Yes, checkboxes are one way to have
multiple choices selected by the end user.

54
Q

What input type do you use to create a checkbox in a form?

A

Checkbox

55
Q

When writing the HTML syntax for checkbox, what 3 properties do you need to use? (V.I.N.)

A

VIN is the acroynm to remember.

V: Value

I: ID

N: Name

56
Q

What would be an example of using, all 3 attributes from VIN, to create a single checkbox?

A