HTML Tutorial
<dl>The <dl> tag defines a description list, which consists of a list of terms and their corresponding descriptions. It's used to organize and present information in a structured manner.
<dl>No specific attributes are associated with the <dl> tag.
<dl>To create a description list, use the <dl> tag to enclose the list of terms and descriptions. Each term should be enclosed in a <dt> tag, and the corresponding description should be enclosed in a <dd> tag.
<dl>
<dt>Term 1</dt>
<dd>Description 1</dd>
<dt>Term 2</dt>
<dd>Description 2</dd>
</dl>
Output:
Term 1
Description 1
Term 2
Description 2
Exploring the <dl> Tag
The <dl> tag provides a flexible way to present information. Here's a simple example to illustrate its usage:
<!DOCTYPE html>
<html>
<head>
<title>Exploring the <dl> Tag</title>
</head>
<body>
<h1>Glossary</h1>
<dl>
<dt>HTML</dt>
<dd>Hypertext Markup Language, used to create web pages.</dd>
<dt>CSS</dt>
<dd>Cascading Style Sheets, used to style web pages.</dd>
</dl>
</body>
</html>
This example defines a glossary of terms. The <dl> tag creates the description list, and the <dt> and <dd> tags are used to specify the terms and descriptions, respectively. The output is a visually appealing and structured glossary.