Unordered List

 

HTML Unordered List

  • An unordered list is a list of items that are not arranged in any specific, sequential order. Unlike ordered lists, the items in an unordered list are typically marked with bullet points, dashes, or other symbols to indicate list membership, but these markers do not imply any particular order.

Syntax for Creating Unordered Lists

cwh tutorial image


Key Characteristics of Unordered Lists

  • No specific sequence is required.
  • Typically displayed as bullet points.
  • Defined using the <ul> tag.
  • Individual items use the <li> tag.

Basic Example

<ul>
  <li>Pen</li>
  <li>Pencil</li>
  <li>Eraser</li>
</ul>

Output:

  • Pen
  • Pencil
  • Eraser

Customizing Bullet Points with 'type' Attribute

You can specify the style of bullet points using the type attribute. It supports three values:

  • disc - default bullet style
  • square
  • circle

Example Using Square Bullets:

<ul type="square">
  <li>Notebook</li>
  <li>Marker</li>
</ul>

Output:

cwh tutorial image

Related Posts:

  • SVG in HTML What is SVG?SVG stands for Scalable Vector Graphics. Unlike raster images like PNGs or JPGs, SVGs are not pixel-based. They're composed of vector… Read More
  • HTML Introduction  What is HTML5?HTML stands for Hypertext Markup LanguageHypertext is Text which contains links to other textsmarkup language it's a way to … Read More
  • Textarea & Select Textarea ElementThe textarea element is used when you need multiline text input from the user. This is particularly useful for comment… Read More
  • HTML FormsThe <form> tag is used to create an HTML form for user input.The <input> HTML element is used to create interactive controls for web-based… Read More
  • More on forms Common AttributesactionThe action attribute specifies the URL where the form data should be sent after submission.<form action="/su… Read More

0 Comments:

Post a Comment

Do leave your comments