HTML Flashcards

1
Q

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

A

In head element

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 body element

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

Give five examples of HTML element types.

A

head element, p element, img element, a element, h1

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

What is the purpose of HTML attributes?

A

To provide additional information about the contents of an element.

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

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

A

© Copyright symbol, ® Registered trademark, “ Quotation mark

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

How do block-level elements affect the document flow?

A

It always appear to start on a new line in the browser window.
h1, p, ul, li

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

How do inline elements affect the document flow?

A

It will always appear to continue on the same line as their neighbouring elements.
Examples of inline elements are a, b, em, img.

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

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

A

The default width of a block-level element is the length of the page.

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

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

A

The height of an inline element is the height of the content.
The width of an inline element is the width of the content

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

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

A

Ordered lists are lists where each item in the list is numbered.
Unordered lists are lists that begin with a bullet point.

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

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

A

List (Ordered, Unordered, Description and List Item) tags ol , ul , dl is a a block element.

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

What HTML tag is used to link to another website?

A

Links are created using the a element which has an attribute called href.

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

What is an absolute URL?

A

It’s a link to a different website.

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

What is a relative URL?

A

Link to other pages within the same site, no need to specify the domain name in the URL

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

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

A

Use ../ to indicate the folder above the current one, then follow it with the file name.

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

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

A

For a child folder, use the name of the child folder, followed by a forward slash, then the file name.

17
Q

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

A

Repeat the ../ to indicate that you want to go up two folders (rather than one), then follow it with the file name. <a>Home</a>

18
Q

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

A

To link to a file in the same folder, just use the file name. (Nothing else is needed.) <a>Reviews</a>

19
Q

What is the purpose of an HTML form element?

A

HTML forms give you a set of elements to collect data from your users

20
Q

Give five examples of form control elements.

A

input, textarea, select, submIt button, radio button

21
Q

Give three examples of type attribute values for HTML elements.

A

search, submit, text, button

22
Q

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

A

input is “inline” element

23
Q

What are the six primary HTML elements for creating tables?

A

A set of ‘table’ and ‘/table’

‘tbody’ The body should sit inside the ‘tbody’ element.

Table headers
A set of ‘th’ and ‘/th’ opening and closing tags respectively are required to create table headers.

Table Rows
A set of ‘tr’ and ‘/tr’ opening and closing tags respectively are required to create a row.

Table Columns
A set of ‘td’ and ‘/td’ opening and closing tags respectively are required to create a column.

24
Q

What purpose do the thead and tbody elements serve?

A

The thead tag is used to group header content in an HTML table. The thead element is used in conjunction with the tbody and tfoot elements to specify each part of a table (header, body, footer).
*thead element must have one or more tags inside.

tbody is used to group the body content in an HTML table.
The tbody tag must be used in the following context: As a child of a element, after any caption, colgroup, and thead elements.