'list-style-type' Example : list style type « CSS « HTML / CSS






'list-style-type' Example

  
    
<html>
<body>
<ol id="myL">
  <li>Item 1.</li>
  <li>Item 2.</li>
  <li>Item 3.</li>
  <li>Item 4.</li>
  <li>Item 5.</li>
</ol>
   <input type="button" 
          value='Set listStyleType to "circle"' 
          onclick="myL.style.listStyleType='circle'">
   <br>
   <input type="button" 
          value='Set listStyleType to "square"' 
          onclick="myL.style.listStyleType='square'">
   <br>
   <input type="button" 
          value='Set listStyleType to "disc"'   
          onclick="myL.style.listStyleType='disc'">
   <br>
   <input type="button" 
          value='Set listStyleType to "lower-alpha"' 
          onclick="myL.style.listStyleType='lower-alpha'">
   <br>
   <input type="button" 
          value='Set listStyleType to "lower-roman"' 
          onclick="myL.style.listStyle='lower-roman'">
</body>
</html>

    
      
        
    
  








Related examples in the same category

1.The list-style-type Property
2.The table that follows lists the popularly supported values for ordered lists.
3.list-style-type: upper-greek
4.list-style-type: square
5.list-style-type: disc
6.list-style-type: circle
7.list-style-type: lower-roman
8.list-style-type: upper-latin
9.list-style-type: lower-latin
10.list-style-type: lower-greek
11.list-style-type: georgian
12.list-style-type: decimal
13.list-style-type: decimal-leading-zero
14.list-style-type: armenian
15.list style type: armenian
16.list style type: decimal and decimal leading zero
17.list style type: georgian
18.list style type: lower greek
19.list style type: lower latin
20.list style type: lower latin, upper latin
21.list style type: lower roman
22.list style type: lower roman upper roman
23.list style type: square, disc, circle
24.list style type: upper greek
25.list style type: upper latin
26.list style type: upper roman
27.list-style-type: upper-roman; list-style-position: inside;
28.list-style-type: decimal; list-style-position: outside;
29.Changing unordered list markers to square
30.UL list-style: none
31.UL list-style-type: disc;
32.list-style-type: none
33.Character marker for list
34.Entity marker
35.list-style-type: lower-latin/upper-latin
36.list-style-type: square/disc/circle