← Images with img, src and alt lesson New set →

HTML Worksheet: Images and Alt Text

HTML and CSS lesson 7: Images with img, src and alt · Set 149 · 40 questions
TalentJR

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. 1.🖼️ How many pixels wide is the picture drawn?
    <img src="cake.jpg" alt="Birthday cake" width="50">
  2. 2.True or false: in <img>, src is read by screen readers. (a) True (b) False
  3. 3.🖼️ How many pixels wide is the picture drawn?
    <img src="map.png" alt="Map of India" width="300">
  4. 4.🖼️ Which attribute of <img> describes the picture? (a) width (b) src (c) height (d) alt
  5. 5.🖼️ Which picture file does the browser load?
    <img src="kite.png" alt="A red kite" width="50">
    (a) kite.png (b) map.png (c) A red kite (d) cake.jpg
  6. 6.🖼️ How many pixels wide is the picture drawn?
    <img src="map.png" alt="Map of India" width="350">
  7. 7.🖼️ Which picture file does the browser load?
    <img src="bus.jpg" alt="Our school bus" width="100">
    (a) tiger.jpg (b) Our school bus (c) bus.jpg (d) fort.jpg
  8. 8.🖼️ Which picture file does the browser load?
    <img src="fort.jpg" alt="An old fort" width="400">
    (a) tiger.jpg (b) An old fort (c) kite.png (d) fort.jpg
  9. 9.🖼️ Which picture file does the browser load?
    <img src="fort.jpg" alt="An old fort" width="100">
    (a) tiger.jpg (b) kite.png (c) fort.jpg (d) An old fort
  10. 10.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="moon.png" alt="The full moon" width="300">
    (a) moon.png (b) The full moon (c) width (d) Our school bus
  11. 11.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="tiger.jpg" alt="A tiger asleep" width="150">
    (a) tiger.jpg (b) A red kite (c) width (d) A tiger asleep
  12. 12.🖼️ Which attribute of <img> is read by screen readers? (a) src (b) alt (c) width (d) height
  13. 13.🖼️ How many pixels wide is the picture drawn?
    <img src="fort.jpg" alt="An old fort" width="150">
  14. 14.🖼️ Why do we add alt text to an image? (a) to describe the image (b) to make it bigger (c) to load it faster (d) to colour it
  15. 15.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="fort.jpg" alt="An old fort" width="150">
    (a) An old fort (b) width (c) A tiger asleep (d) fort.jpg
  16. 16.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  17. 17.🖼️ Which picture file does the browser load?
    <img src="map.png" alt="Map of India" width="50">
    (a) map.png (b) cake.jpg (c) Map of India (d) dog.jpg
  18. 18.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="bus.jpg" alt="Our school bus" width="150">
    (a) Our school bus (b) An old fort (c) bus.jpg (d) width
  19. 19.True or false: in <img>, width sets how wide it is. (a) True (b) False
  20. 20.True or false: in <img>, src tells which image to load. (a) True (b) False
  21. 21.True or false: in <img>, alt sets how tall it is. (a) False (b) True
  22. 22.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="kite.png" alt="A red kite" width="50">
    (a) kite.png (b) Map of India (c) width (d) A red kite
  23. 23.True or false: in <img>, height describes the picture. (a) False (b) True
  24. 24.🖼️ How many pixels wide is the picture drawn?
    <img src="tiger.jpg" alt="A tiger asleep" width="50">
  25. 25.🖼️ Which attribute of <img> shows if the image fails? (a) height (b) src (c) alt (d) width
  26. 26.🖼️ How many pixels wide is the picture drawn?
    <img src="tiger.jpg" alt="A tiger asleep" width="250">
  27. 27.True or false: in <img>, alt shows if the image fails. (a) True (b) False
  28. 28.🖼️ Which picture file does the browser load?
    <img src="kite.png" alt="A red kite" width="150">
    (a) map.png (b) cake.jpg (c) A red kite (d) kite.png
  29. 29.True or false: in <img>, src names the picture file. (a) True (b) False
  30. 30.True or false: in <img>, width sets how tall it is. (a) False (b) True
  31. 31.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="250">
    (a) map.png (b) A tiger asleep (c) kite.png (d) tiger.jpg
  32. 32.🖼️ How many pixels wide is the picture drawn?
    <img src="fort.jpg" alt="An old fort" width="50">
  33. 33.🖼️ Which attribute of <img> tells which image to load? (a) alt (b) src (c) width (d) height
  34. 34.🖼️ Which tag puts a picture on a page? (a) <pic> (b) <a> (c) <p> (d) <img>
  35. 35.True or false: in <img>, height shows if the image fails. (a) True (b) False
  36. 36.True or false: in <img>, width tells which image to load. (a) False (b) True
  37. 37.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="kite.png" alt="A red kite" width="300">
    (a) kite.png (b) width (c) Map of India (d) A red kite
  38. 38.🖼️ Which picture file does the browser load?
    <img src="kite.png" alt="A red kite" width="400">
    (a) cake.jpg (b) A red kite (c) kite.png (d) map.png
  39. 39.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="kite.png" alt="A red kite" width="200">
    (a) kite.png (b) A red kite (c) width (d) Map of India
  40. 40.True or false: in <img>, height sets how tall it is. (a) True (b) False

Answer key

  1. 50
  2. False
  3. 300
  4. alt
  5. kite.png
  6. 350
  7. bus.jpg
  8. fort.jpg
  9. fort.jpg
  10. The full moon
  11. A tiger asleep
  12. alt
  13. 150
  14. to describe the image
  15. An old fort
  16. No
  17. map.png
  18. Our school bus
  19. True
  20. True
  21. False
  22. A red kite
  23. False
  24. 50
  25. alt
  26. 250
  27. True
  28. kite.png
  29. True
  30. False
  31. tiger.jpg
  32. 50
  33. src
  34. <img>
  35. False
  36. False
  37. A red kite
  38. kite.png
  39. A red kite
  40. True

Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids