HTML Flashcards

(47 cards)

1
Q

Where do you put visible content about the HTML document?

A

«a>body</a>>«a>/body</a>>

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

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

A

«a>head</a>>«a>/head</a>>

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

«a>html</a>>«a>/html</a>>

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

What is the purpose of a declaration?

A

to declare what version of HTML the page is being written witih

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

Give five examples of HTML element tags.

A

«a>head</a>>«a>/head</a>>, «a>body</a>>«a>/body</a>>, «a>h1</a>>«a>/h1</a>>, «a>header</a>>«a>/header</a>>, «a>h2</a>>«a>/h2</a>>

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

It gives or modifies the functionality of an element

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

Where do you put visible content about the HTML document?

A

«a>body</a>>«a>/body</a>>

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

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

A
(with no space before semi-colon and after &)
& amp ; is &
& lt ; is <
& lt ; is >
& #34 ; is "
& #39 ; is '
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

How do block-level elements affect the document flow?

A

They take up all the horizontal space and only as much height as its content

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

How do inline elements affect the document flow?

A

They take up only as much height and horizontal space as necessary for 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 a block-level element?

A

All of the horizontal as much height as necessary

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

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

A

as much height and width as necessary for element

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

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

A

ordered list is numbered and unordered list is bullet points

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

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

A

«a>block</a>>«a>/block</a>>

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

What HTML tag is used to link to another website?

A

«a>a</a>>«a>/a</a>>

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

What is an absolute URL?

A

A full url that leads to another website

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

What is a relative URL?

A

a link that sends you to another page within the same site

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

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

A

../index.html

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

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

A

example/index.html

20
Q

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

A

../../index.html

21
Q

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

22
Q

Give five examples of form control elements.

A

input, text area, select, option, button

23
Q

Give three examples of type attributes for HTML elements.

A

«a>input type=”checkbox”</a>>«a>/input</a>>
«a>input type=”submit”</a>>«a>/input</a>>
«a>input type=”radio”</a>>«a>/input</a>>

24
Q

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

A

inline element

25
What is the purpose of an HTML form element?
to hold/store form content
26
What are the six primary HTML elements for creating tables?
tr, td, th, thead, tbody, tfoot
27
What purpose do the thead and tbody elements serve?
headings of the table should be in the thead element and the body of the table should be in the tbody element
28
Give two examples of data that would lend itself well to being displayed in a table.
Keeping track of ticket sales and keeping track of how many hours you worked out in a month
29
Name three different types of values you can use to specify colors in CSS.
hex codes, rgb css function, color names
30
What CSS properties make up the box model?
Content, padding, border, margin
31
Which CSS property pushes boxes away from each other?
margin
32
Which CSS property add space between a box's content and its border?
padding
33
What is a pseudo-class?
It is a keyword added to a selector that specifies a special state of the selected element
34
What are CSS pseudo-classes useful for?
It lets you apply a style to the element when it is in a special state or also to external factors like history with the element
35
Name at least two units of type size in CSS.
pixels and percentages
36
What CSS property controls the font used for the text inside an element?
font-family
37
What is the default flex-direction of a flex container?
row
38
What is the default flex-wrap of a flex container?
inline
39
Why do two div elements "vertically stack" on one another by default?
because div elements are block level elements
40
What is the default flex-direction of an element with display: flex?
row
41
What is the default value for the position property of HTML elements?
static
42
How does setting position: relative on an element affect document flow?
it originally takes place in the normal layout flow, you can modify its final position, which could lead to it overlapping other elements
43
How does setting position: relative on an element affect where it appears on the page?
It does not affect it at all unless you also apply top. bottom, left, or right to it
44
How does setting position: absolute on an element affect document flow?
It makes the element not a part of the document flow and it now sits on its own layer
45
How does setting position: absolute on an element affect where it appears on the page?
It will make it appear at the very top of the page over other elements in the regular document flow.
46
How do you constrain an absolutely positioned element to a containing block?
If the position property is absolute, the containing block is formed by the edge of the padding box of the nearest ancestor element that has a position value other than static
47
What are the four box offset properties?
static, fixed, absolute, relative