Creating Definition Lists

A definition list is just what it sounds like: a list in which terms are presented and then defined, such as in a glossary. The word being defined serves as a heading, and the definition paragraph is indented under it.

Creating Definition Lists

The complete list (headings and definition paragraphs) is contained within a <dl> tag, which stands for definition list. Each word to be defined is contained in a <dt> (definition term) tag, and the definition paragraphs are in <dd> (definition description) tags. Here’s the code for the example just shown:

<dl> <dt>Fungus</dt> <dd>A primitive, non-vascular, non-photosynthetic form of plant life. Examples include ...

Get HTML and XHTML Step by Step now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.