Css :- List style

<!DOCTYPE html> 

<html> 

 

<head> 

 <meta name="viewport" content="width=device-width, initial-scale=1"> 

 

 <style> 

  .ul1 { 

   list-style-type: circle; 

  } 

   

  .ul2 { 

   list-style-type: square; 

  } 

   

  .ol1 { 

   list-style-type: upper-roman; 

  } 

   

  .ol2 { 

   list-style-type: lower-alpha; 

  } 

 </style> 

 

</head> 

 

<body> 

 

 <p>Example of unordered lists:</p> 

 <ul class="ul1"> 

  <li>Coffee</li> 

  <li>Tea</li> 

  <li>Coca Cola</li> 

 </ul> 

 

 <ul class="ul2"> 

  <li>Coffee</li> 

  <li>Tea</li> 

  <li>Coca Cola</li> 

 </ul> 

 

 <p>Example of ordered lists:</p> 

 <ol class="ol1"> 

  <li>Coffee</li> 

  <li>Tea</li> 

  <li>Coca Cola</li> 

 </ol> 

 

 <ol class="ol2"> 

  <li>Coffee</li> 

  <li>Tea</li> 

  <li>Coca Cola</li> 

 </ol> 

 

</body> 

 

</html>



Used of:-

List Style


  • The list-style-type specifies the type of list-item shape in a list.
  • Several shapes can be used for listing.
  • By default it is a filled circle.
  • Some shapes are
    • circle
    • square
    • upper-roman
    • lower-alpha
Css :- List style Css :- List style Reviewed by Network security on May 06, 2019 Rating: 5

No comments:

Useful Information

Powered by Blogger.