HTML Flashcards

1
Q

Where do you put non-visible content about the HTML document?

A

In the head element of the HTML document.

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

Where do you put visible content about the HTML document?

A

In the body element of the HTML document.

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

Where do the head and body tags go in a valid HTML document?

A

In the html element of the HTML document.

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

What is the purpose of a doctype declaration?

A

The doctype declaration tells the browser which version of HTML the document is written in.

(!doctype html tells the browser that the document is written in HTML5)

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

Give five examples of HTML element types.

A

html, head, title, body, and h1-h6.

(p, span, a, ol, ul, li, em, strong, del, ins, etc.)

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

What is the purpose of HTML attributes?

A

The purpose of HTML attributes is to provide additional information about HTML elements.

(Color, size, and other features)

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

Give an example of an HTML entity (escape character).

A

Ampersand, copyright, and registered trademark are a few examples of HTML entities.

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

How do block-level elements affect the document flow?

A

Block-level elements force a new line to begin in the document flow.

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

How do inline elements affect the document flow?

A

Inline elements do not force a new line to begin in the document flow.

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

What are the default width and height of a block-level element?

A

The default width of a block-level element is the width of its parent element.

The default height of a block-level element is the height of its contents.

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

What are the default width and height of an inline element?

A

The default width of an inline element is the width of its contents.

The default height of an inline element is the height of its contents.

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

What is the difference between an ordered list and an unordered list in HTML?

A

Ordered lists create a list of related items in a specific order using numerical values.

Unordered lists create a list of related items in no particular order using bullets.

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

Is an HTML list a block element or an inline element?

A

An HTML list is a block element because each list item starts on a new line.

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

What HTML tag is used to link to another website?

A

The HTML tag used to link to another website is the a (or anchor) tag.

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

What is an absolute URL?

A

An absolute URL contains a domain name which points the user to a file on a different website.

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

What is a relative URL?

A

A relative URL contains a file path which points the user to a file on the same website.

17
Q

How do you indicate the relative link to a parent directory?

A

The relative link to a parent directory is indicated by “../”.

18
Q

How do you indicate the relative link to a child directory?

A

The relative link to a child directory is indicated by “folder name/file name”.

19
Q

How do you indicate the relative link to a grand parent directory?

A

The relative link to a grand parent directory is indicated by “../../”.

20
Q

How do you indicate the relative link to the same directory?

A

The relative link to the same directory is indicated by “file name”.

21
Q

What is the purpose of an HTML form element?

A

The purpose of an HTML form element is to represent a section of a document used for submitting information.

22
Q

Give five examples of form control elements.

A

form, input, textarea, select, option.

23
Q

Give three examples of type attribute values for HTML input elements.

A

text, password, and radio.

(checkbox, file, submit, image, hidden, date, email, url, search, etc.)

24
Q

Is an HTML input element a block element or an inline element?

A

The HTML input element is an inline-block element.

25
Q

What are the six primary HTML elements for creating tables?

A

table, tr, td, th, thead, and tbody.

(there is also tfoot)

26
Q

What purpose do the thead and tbody elements serve?

A

The thead element defines a set of rows that serve as a table’s column headers.

The tbody element defines a set of rows that serve as a table’s content.

27
Q

Give two examples of data that would lend itself well to being displayed in a table.

A

A schedule or leaderboard