Definition Lists

  •  A Definition List in HTML is used to represent a list of terms along with their corresponding descriptions or definitions. The Definition List is created using the <dl> (Definition List) element, which wraps around one or more pairs of <dt> (Definition Term) and <dd> (Definition Description) elements.

cwh tutorial image

Definition List Example

Here's a simple example to illustrate:

  <h1>HTML Definition List</h1>
  <dl>
    <dt>HTML</dt>
    <dd>HyperText Markup Language: The standard language for creating web pages.</dd>

    <dt>CSS</dt>
    <dd>Cascading Style Sheets: A stylesheet language used for describing the look and formatting of a document written in HTML.</dd>

    <dt>JavaScript</dt>
    <dd>A programming language commonly used in web development to add interactive features.</dd>
  </dl>

Understanding the example

In this example:

  • <dl> is the container for the list.
  • <dt> defines the terms that you want to explain.
  • <dd> contains the definitions or explanations for the terms.

Related Posts:

  • Anchor Tag <a> tag defines a hyperlink, which is used to link from one page to another page.Key Characteristics of HTML Anchor LinksSpecified by the … Read More
  • Paragraph Horizontal and Line Break Tags The <p> tag defines a paragraph.Browsers automatically add a single blank line before and after each.<p>This is a paragraph.</p&g… Read More
  • HTML Attributes What is an HTML Attribute?HTML attributes provide additional information about HTML elements. Attributes are always specified in the start … Read More
  • HTML Comments it is used to understand the code written by someone.the browser will ignore the comments Types of Comments in HTMLSingle-line CommentsSing… Read More
  • HTML Page Structure Understanding the Structure of an HTML Document <!DOCTYPE html> // let browser know it's an HTML5 Document.<html> // Root of an… Read More

0 Comments:

Post a Comment

Do leave your comments