HTML Worksheet: Images and Alt Text
Code tip (File and words): <img src="file.jpg" alt="what it shows" width="200"> — no closing tag. src = which file to load; alt = words describing it; width / height = size in pixels. If the picture fails, the browser shows the alt text; screen readers read it aloud.
NameDateTime takenScore ___ / 40
-
1.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="moon.png" alt="The full moon" width="350"> (a) Our school bus (b) moon.png (c) The full moon (d) width - 2.True or false: in <img>, height names the picture file. (a) False (b) True
- 3.🖼️ Which tag puts a picture on a page? (a) <p> (b) <a> (c) <pic> (d) <img>
- 4.True or false: in <img>, alt is read by screen readers. (a) True (b) False
- 5.True or false: in <img>, alt describes the picture. (a) False (b) True
-
6.🖼️ How many pixels wide is the picture drawn?
<img src="kite.png" alt="A red kite" width="250"> -
7.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="dog.jpg" alt="A happy dog" width="250"> (a) A happy dog (b) width (c) The full moon (d) dog.jpg - 8.🖼️ Does <img> need a closing tag? (a) Yes (b) No
-
9.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="200"> (a) tiger.jpg (b) width (c) A red kite (d) A tiger asleep -
10.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="150"> (a) A red kite (b) kite.png (c) map.png (d) cake.jpg - 11.🖼️ Which attribute of <img> sets how wide it is? (a) src (b) height (c) width (d) alt
-
12.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="fort.jpg" alt="An old fort" width="200"> (a) fort.jpg (b) width (c) An old fort (d) A tiger asleep - 13.🖼️ Why do we add alt text to an image? (a) to make it bigger (b) to load it faster (c) to colour it (d) to describe the image
-
14.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="250"> (a) tiger.jpg (b) A tiger asleep (c) width (d) A red kite - 15.True or false: in <img>, height shows if the image fails. (a) True (b) False
-
16.🖼️ Which picture file does the browser load?
<img src="tiger.jpg" alt="A tiger asleep" width="50"> (a) tiger.jpg (b) kite.png (c) A tiger asleep (d) map.png - 17.True or false: in <img>, src tells which image to load. (a) False (b) True
- 18.True or false: in <img>, width sets how wide it is. (a) True (b) False
-
19.🖼️ Which picture file does the browser load?
<img src="kite.png" alt="A red kite" width="250"> (a) kite.png (b) A red kite (c) map.png (d) cake.jpg -
20.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="fort.jpg" alt="An old fort" width="50"> (a) fort.jpg (b) width (c) A tiger asleep (d) An old fort - 21.🖼️ Which attribute of <img> describes the picture? (a) width (b) alt (c) src (d) height
-
22.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="tiger.jpg" alt="A tiger asleep" width="300"> (a) tiger.jpg (b) A tiger asleep (c) width (d) A red kite - 23.True or false: in <img>, width describes the picture. (a) True (b) False
-
24.🖼️ Which picture file does the browser load?
<img src="moon.png" alt="The full moon" width="150"> (a) fort.jpg (b) The full moon (c) bus.jpg (d) moon.png -
25.🖼️ How many pixels wide is the picture drawn?
<img src="moon.png" alt="The full moon" width="100"> -
26.🖼️ How many pixels wide is the picture drawn?
<img src="cake.jpg" alt="Birthday cake" width="300"> - 27.True or false: in <img>, width names the picture file. (a) True (b) False
-
28.🖼️ How many pixels wide is the picture drawn?
<img src="tiger.jpg" alt="A tiger asleep" width="250"> -
29.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="kite.png" alt="A red kite" width="200"> (a) Map of India (b) A red kite (c) width (d) kite.png -
30.🖼️ How many pixels wide is the picture drawn?
<img src="map.png" alt="Map of India" width="300"> -
31.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="cake.jpg" alt="Birthday cake" width="350"> (a) A happy dog (b) cake.jpg (c) Birthday cake (d) width - 32.True or false: in <img>, width shows if the image fails. (a) True (b) False
-
33.🖼️ How many pixels wide is the picture drawn?
<img src="tiger.jpg" alt="A tiger asleep" width="50"> -
34.🖼️ How many pixels wide is the picture drawn?
<img src="fort.jpg" alt="An old fort" width="100"> -
35.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="cake.jpg" alt="Birthday cake" width="300"> (a) cake.jpg (b) A happy dog (c) width (d) Birthday cake - 36.🖼️ Which attribute of <img> tells which image to load? (a) width (b) height (c) src (d) alt
- 37.True or false: in <img>, height is read by screen readers. (a) False (b) True
-
38.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="moon.png" alt="The full moon" width="250"> (a) Our school bus (b) moon.png (c) The full moon (d) width - 39.🖼️ Which attribute of <img> is read by screen readers? (a) height (b) width (c) src (d) alt
-
40.🖼️ The picture cannot load. Which text does the browser show instead?
<img src="map.png" alt="Map of India" width="50"> (a) Birthday cake (b) width (c) Map of India (d) map.png
Answer key
- The full moon
- False
- <img>
- True
- True
- 250
- A happy dog
- No
- A tiger asleep
- kite.png
- width
- An old fort
- to describe the image
- A tiger asleep
- False
- tiger.jpg
- True
- True
- kite.png
- An old fort
- alt
- A tiger asleep
- False
- moon.png
- 100
- 300
- False
- 250
- A red kite
- 300
- Birthday cake
- False
- 50
- 100
- Birthday cake
- src
- False
- The full moon
- alt
- Map of India
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids