2.3 Images Flashcards

(12 cards)

1
Q

What is the <img></img> tag used for?

A

To embed images in an HTML Page.

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

What does the src attribute in <img></img> define?

A

It specifies the path to the image file.

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

What is the purpose of the alt attribute?

A

Provides alternative text for screen readers & when images fail to load.

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

What is alt attribute important for accessibility?

A

It helps visually impaired users understand the content via screen readers.

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

How do you specify the dimensions of an image in HTML?

A

Use width & height attributes (e.g, width=”200”), though CSS is preferred.

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

What are common image formats used on the web?

A

JPG, PNG, GIF, SVG & WebP.

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

What is JPG best suited for?

A

Photographers & images with many colors.

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

What PNG best used for?

A

Images needing transparency or lossless compression.

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

What is GIF format best for?

A

Simple animations & low-color images.

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

What is SVG used for?

A

Scalable vector graphics ideal for logos & icons.

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

What is WebP & Why use it?

A

A modern image format offering superior compression with quality.

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

Can you make an image clickable in HTML?

A

Yes, wrap it in an anchor tag: <a><img></img></a>.

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