HTML Flashcards

1
Q

Where the non-visible content of the HTML document goes

A

In between the “head” element’s opening & closing tags

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

Where the visible content of the HTML document goes

A

In between the “body” element’s opening & closing tags

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 HTML document?

A

In between the “html” element’s opening & closing tags

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

What is purpose of the DOCTYPE declaration?

A

Lets browser know what version of HTML is being used (HTML5)

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

What is the purpose of HTML attributes?

A

Gives more information or data about the HTML element

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

Give an example of an HTML entity (escape character)

A

Multiplication: & # 215 ; or & times ;
Copyright: & # 169 ; or & copy ;

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

Give five examples of HTML element tags.

A

< body > , < head > , < html >, < div >, < header >

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

What is the difference between an unordered list & ordered list?

A

Unordered - bullet points

Ordered - numbers

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

How to build a description list?

A

“dl” (description list)
“dt” (description term)
“dd” (description definition)

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

What is an absolute URL?

A

Full web address for a website (domain name then path to specific page)

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

What is a relative URL?

A

Shorthand for linking to pages on the same site (don’t need to specify the domain name)

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

What are other ways we can use an anchor tag?

A
  • Directing to other sections of same webpage
  • Downloading files
  • Link to email or phone number
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

How do you indicate the parent folder in a path?

A

.. / fileName

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

How do you indicate the child folder in a path?

A

folderName / fileName

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

How do you indicate the grandparent folder in a path?

A

.. / .. / fileName

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

How do you indicate the current folder in a path?

A

.

17
Q

What are the six primary HTML elements for creating tables?

A
table
th
tr
td
thead
tbody
tfoot
18
Q

What purpose do the thead and tbody elements serve?

A

thead - the headings sit in here
tbody - the body of the table goes here
* Helps with screen readers and styling

19
Q

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

A

Schedule and pricing table

20
Q

Why are forms useful?

A

Collects and sends user supplied data to server for processing and storage

21
Q

What attribute do you have to match between a label and an input?

A

label - for

input - id

22
Q

What type of input allows you to select multiple items in a dropdown?

A

“select” element + “option” elements

23
Q

What is the action of a form?

A

Where the browser will send the form data

24
Q

What is the purpose of an HTML form?

A

Allows you to collect data from users

25
Q

Give five examples of form control elements.

A

text area, radio buttons, dropdown list boxes, checkbox, password input

26
Q

Give three examples of type attributes for HTML input elements.

A

Password, text, number

27
Q

Why would we use semantic elements over div or span?

A
  • Easier to read
  • Screen readers use to navigate for visually impaired
  • Search engines use contents and important keywords to influence page’s search rankings
28
Q

What factors contribute to a well-designed HTML document?

A
  • Readability

- Separation of concerns

29
Q

How do block-level elements affect the document flow?

A

Block elements display one after another, vertically
New line
Takes available width
Makes the next element take a new line after

30
Q

How do inline elements affect the document flow?

A

Inline elements are displayed in the inline direction, horizontally
As much as the content takes up

31
Q

What accessibility considerations must be considered when choosing HTML elements?

A

Screen readers for people with visual disabilities are better able to read semantic elements versus generic ones like div which give no additional context