Solice UI
Back to the curriculum

Chapter 2 · HTML & Semantics

Links, images, and media

Links and media are central to the Web, but they need context. A useful link explains its destination, while an image needs dimensions and an alternative that matches its purpose.

Beginner · Lesson 4 of 6 in this chapter

Links promise navigation

An anchor with an href should lead somewhere. Link text such as “Read the accessibility guide” is more useful than “Click here” because it still makes sense when read out of context.

Media should fit the content

Images can communicate information, reinforce text, or decorate a layout. Informative images need a concise alternative; decorative images can use an empty alternative so they do not create noise.

Adding a product illustration

  1. Set intrinsic width and height so the page reserves space.
  2. Write alternative text only if the illustration adds information.
  3. Place a separate link nearby if the user must navigate; do not make an unexplained picture the only control.
  • Link text should describe the destination.
  • Alternative text depends on an image's purpose.
  • Reserve media space to keep the page stable while it loads.