HTML Flashcards

1
Q

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

A

Non-visible content, known as metadata (or data about data), is stored in the element. This data includes page description, keywords, author, charset, etc.

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

Visible content, content that is seen on the page, is stored in the element. The body contains all the visible content of an HTML document, such as the headings, paragraphs, images, lists, hyperlinks, etc.

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

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

A

The element is placed between the tag and the tag. The tag is placed after the closing tag and before the closing tag.

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

The DOCTYPE declaration tells the browser what version of markup language (HTML, XML) in which a webpage is written.

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

Metadata elements: , ,
Root elements:
Content Sectioning: , <h1>, <h2>, ,
Text content: <div>, <li>, , <ol>, <p>, </p></ol><ul>
Inline: <a>, <b>, <em>, , <span></span></em></b></a></ul></li></div></h2></h1>

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

Elements in HTML have attributes, which are values that configure the elements or adjust their behavior in various ways.

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

Inverted question-mark ( ¿ ): ¿

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

In normal flow, block-level elements stack upon each-other, occupying the entire width of the parent container. A block-level element always starts on a new line and the browser automatically adds some space (a margin) before and after the element.

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 sit inside the content of block-level elements. Their size is the just the required size of their content. You cannot set width or height on inline elements without setting it to behave like a block level element.

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 100% of the width of its parent container. The default height is the height of the content.

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 and height of an inline element are the width and height of the content.

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

An ordered list <ol> has items ordered by number while an unordered list </ol><ul> simply has bullet points.</ul>

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. This applies to both the ul, ol elements as well as li elements.

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

To link to another website, we use the <a> tag which defines a hyperlink. The </a><a> element has its href attribute, which indicates the destination of the link.</a>

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 is the full URL, including the protocol ((HTTP, HTTPS), the option subdomain (www), domain (example.com), and path (example.com/about).

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 only includes the path as it assumes the link is on the same site and part of the same root domain.

17
Q

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

A

You can indicate the relative link to a parent directory by using ‘../’ to access the contents of the parent directory.

18
Q

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

A

You can indicate the relative link to a child directory by simply writing the path in the link. This is assuming that the content is relative to the directory in which the current page is located.

19
Q

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

A

Similar to accessing the parent directory, you would instead use ‘../../’

20
Q

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

A

The relative link to the same directory would simply use the single dot ‘./’

21
Q

What is the purpose of an HTML form element?

A

The form element allows for interactive controls in which user can input and submit information.

22
Q

Give five examples of form control elements

A
23
Q

Give three examples of type attribute values for HTML elements.

A

Three examples of type attribute values

24
Q

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

A

The element are either inline or inline-block.

25
Q

What are the six primary HTML elements for creating tables?

A

th tr td table thead tbody

26
Q

What purpose do the thead and tbody elements serve?

A

is used to group header content while is used to group body content

27
Q

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

A

A table is used to store relational data. This can be in the form of a professional athlete’s statistics from a variety of statical criteria stored in each header cell. Another example would be a calendar that shows a person’s hourly schedule for each day of the week.