AgerNic.com
WEB DEVELOPER SITE, HTML, CSS, PHP, SQL
HTML Tutorial

HTML List Style Type list-style-type


HTML Tutorial » HTML List Style Type

HTML contains some useful tags for displaying content as lists. This makes the text easier to read and highlight.
HTML offers three ways to specify information lists. All lists must contain one or more item lists.

The types of lists that can be used in HTML are:
ul: An unordered list. It will list the items in a box.
ol: A ordered list. This will use different number schemes to list your items.
dl: A list of definitions. This arranges the articles in the same way they are arranged in a dictionary.

We can add  list-style-type property to web page in different ways as:
Inline - by using the style attribute in HTML elements
Internal - by using a <style> element in the <head> section
External - by using an external CSS file as style.css

Syntax:

/* Partial list of types */
list-style-type: armenian
list-style-type: circle
list-style-type: decimal
list-style-type: decimal-leading-zero
list-style-type: disc
list-style-type: georgian
list-style-type: inherit
list-style-type: lower-alpha
list-style-type: lower-greek
list-style-type: lower-latin
list-style-type: lower-roman
list-style-type: none
list-style-type: square
list-style-type: upper-alpha
list-style-type: upper-latin
list-style-type: upper-roman

/* value */
list-style-type: '-';

/* Identifier matching an @counter-style rule */
list-style-type: custom-counter-style;

/* Keyword value */
list-style-type: none;

/* Global values */
list-style-type: inherit;
list-style-type: initial;
list-style-type: unset;
Note: use external CSS instead


Different list item markers of list-style-type - examples


The list-style-type specifies the type of list-item marker in a list.

Example:
Example 1, This example demonstrates all the different list item markers of list-style-type:

 
    <!DOCTYPE html>
<html>
<head>
<style>
ul.a22 {list-style-type: circle;}
ul.b22 {list-style-type: disc;}
ul.c22 {list-style-type: square;}
ol.d22 {list-style-type: armenian;}
ol.e22 {list-style-type: cjk-ideographic;}
ol.f22 {list-style-type: decimal;}
ol.g22 {list-style-type: decimal-leading-zero;}
ol.h22 {list-style-type: georgian;}
ol.i22 {list-style-type: hebrew;}
ol.j22 {list-style-type: hiragana;}
ol.k22 {list-style-type: hiragana-iroha;}
ol.l22 {list-style-type: katakana;}
ol.m22 {list-style-type: katakana-iroha;}
ol.n22 {list-style-type: lower-alpha;}
ol.o22 {list-style-type: lower-greek;}
ol.p22 {list-style-type: lower-latin;}
ol.q22 {list-style-type: lower-roman;}
ol.r22 {list-style-type: upper-alpha;}
ol.s22 {list-style-type: upper-greek;}
ol.t22 {list-style-type: upper-latin;}
ol.u22 {list-style-type: upper-roman;}
ol.v22 {list-style-type: none;}
ol.w22 {list-style-type: inherit;}
</style>
</head>
<body>

<h1>The list-style-type Property</h1>

<ul class="a22">
<li>Circle type</li>
<li>Item1</li>
<li>Item2</li>
</ul>

<ul class="b22">
<li>Disc type</li>
<li>Item1</li>
<li>Item2</li>
</ul>

<ul class="c22">
<li>Square type</li>
<li>Item1</li>
<li>Item2</li>
</ul>

<ol class="d22">
<li>Armenian type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="e22">
<li>Cjk-ideographic type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="f22">
<li>Decimal type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="g22">
<li>Decimal-leading-zero type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="h22">
<li>Georgian type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="i22">
<li>Hebrew type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="j22">
<li>Hiragana type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="k22">
<li>Hiragana-iroha type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="l22">
<li>Katakana type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="m22">
<li>Katakana-iroha type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="n22">
<li>Lower-alpha type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="o22">
<li>Lower-greek type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="p22">
<li>Lower-latin type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="q22">
<li>Lower-roman type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="r22">
<li>Upper-alpha type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="s22">
<li>Upper-greek type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="t22">
<li>Upper-latin type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="u22">
<li>Upper-roman type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="v22">
<li>None type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

<ol class="w22">
<li>inherit type</li>
<li>Item1</li>
<li>Item2</li>
</ol>

</body>
</html>

Note: Use external CSS instead.


How to add bullet colors - examples


How to add bullet colors for <ul> or <ol> by removing their default bullets and adding a HTML entity that looks like bullets (•):

Example: How to add bullet colors - examples:
How to add bullet colors - examples
        <!DOCTYPE html>
<html>
<head>
<title>How to add bullet colors - example</title>

<style>
ul {
list-style: none; /* Remove HTML bullets */
padding: 0;
margin: 0;
}

li {
padding-left: 16px;
}

li::before {
content: "•"; /* Insert content that looks like bullets */
padding-right: 8px;
color: blue; /* Or a color you prefer */
}
</style>
</head>
<body>

<h1>How to add bullet colors. The content Property</h1>

<ul>
<li>Coffee</li>
<li>Tea</li>
<li>Coca Cola</li>
</ul>

</body>
</html



html list style type, bullet, arrow, none dash, color, not working, checkmark, number
HTML List Style Type - html tutorial

Online Editor
ONLINE EDITOR

news templates


COLOR PICKER

news templates
This tool makes it easy to create, adjust, and experiment with custom colors for the web.


HTML Templates
news templates
Magnews2 is a modern and creative free magazine and news website template that will help you kick off your online project in style.


CSS HTML Layout
news templates
Find here examples of creative and unique website layouts.


Free CSS HTML Menu
news templates
Find here examples of creative and unique website CSS HTML menu.


HTML Img Background
HTML Image Link
HTML Image Size
HTML Text Style
HTML Text Align
HTML Text Size
HTML Text Color Style
HTML Text Color
HTML Table Color
HTML Table Row Colspan
HTML Table Width
HTML Table Style
HTML Table Border
HTML Table
HTML Font Face
HTML Font Size
HTML Font Color
HTML Headings
HTML div border color
HTML div class
HTML class container
HTML form action
HTML comment
HTML link new tab
HTML link underline
HTML link tag
HTML button action
HTML button onclick
HTML button link
HTML table style
HTML image
HTML colors
HTML div style
Text, paragraf in HTML
HTML Tags Attributes
HTML - Elements
HTML Introduction
Home HTML Tutorial
Online Editor
ONLINE EDITOR

news templates


COLOR PICKER

news templates
This tool makes it easy to create, adjust, and experiment with custom colors for the web.


HTML Templates
news templates
Magnews2 is a modern and creative free magazine and news website template that will help you kick off your online project in style.


CSS HTML Layout
news templates
Find here examples of creative and unique website layouts.


Free CSS HTML Menu
news templates
Find here examples of creative and unique website CSS HTML menu.