4.1 Semantic HTML5 Elements Flashcards

(19 cards)

1
Q

What is semantic HTML?

A

Semantic HTML uses meaningful tags that clearly describe their purpose (e.g, <article>, <nav>), improving structure, accessibility, & SEO.

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

Why is semantic HTML important for SEO?

A

It helps search engines better understand your page structure & content relevance.

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

Why is semantic HTML important for accessibility?

A

It helps screen readers & assistive tech interpret the page meaning correctly.

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

Why is semantic HTML important for developers?

A

It improves code readability & maintainability, making it easier to collaborate.

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

What is the <header> tag used for?

A

Defines introductory content or heading of a page or section (e.g, logo, nav).

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

Can multiple <header> element be used in one HTML document?

A

Yes, one for the page & others for individual sections or articles.

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

What is the <nav> tag used for?

A

Contains navigation links for the site or section.

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

What is the <main> element used for?

A

Wraps the main content of a page, unique & central to the document.

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

How many <main> tag should be on a page?

A

Only one, as it represents the dominant content.

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

What is <article> tag used for?

A

Contains independent, self-contained content like blog posts or news items.

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

What is the <section> tag used for?

A

Groups related content within a page, often with a heading.

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

What is the difference between <article> & <section>?

A

<article> is for standalone content, <section> is for thematic grouping.
</section></article>

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

What is the <aside> tag used for?

A

Contains secondary content like sidebars, callouts, or related links.

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

What is the <figure>element for?</figure>

A

Encapsulates media content (image, Chart) & its caption.

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

What does <figcaption> do?

A

Provides a caption or description for the content inside<figure>.</figure>

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

Can <figcaption> appear before or after the media in <figure>?</figure>

A

Yes, it can be placed before or after the media in <figure> block.</figure>

17
Q

What is the <time> element used for?</time>

A

Represents a specific time or date, optionally with datetime for machine-readable format.

18
Q

How do you use <time>Today</time>?

A

The datetime attribute provides a machie-readable timestamp.

19
Q

Why use <time> instead of a regular <span> for dates?</span></time>

A

Improves semantic structure & enables features like calendar tools & search engines.