List item alignment - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:UL Alignment

Description

List item alignment

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
ol#method-2 {<!-- w w w  .j a  v  a2s  .com-->
   list-style-type:upper-roman;
}

ul, ul li {
   list-style-type:none;
}

span {
   display:inline-block;
   width:21px;
   text-align:right;
}
</style> 
 </head> 
 <body> 
  <h3>Lorem ips</h3> 
  <ol type="I"> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
  </ol> 
  <h3>Lorem ips</h3> 
  <ol id="method-2"> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
   <li>Lorem ips</li> 
  </ol> 
  <h3>Lorem ips</h3> 
  <ul> 
   <li> <span>Lo</span>Lorem ipsum</li> 
   <li> <span>Lor</span>Lorem ipsum</li> 
   <li> <span>Lore</span>Lorem ipsum</li> 
   <li> <span>Lor</span>Lorem ipsum</li> 
   <li> <span>Lo</span>Lorem ipsum</li> 
  </ul>  
 </body>
</html>

Related Tutorials