Evenly distribute li items - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:UL Element

Description

Evenly distribute li items

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">
.steps {<!--   w w  w  . j  a v  a 2s .  co  m-->
   width:100%;
   list-style-type:none;
   padding:0;
   margin:0 auto;
   background:url('https://www.java2s.com/style/demo/Google-Chrome.png') repeat-x;
}

.steps li {
   width:21%;
   float:left;
   right:201px;
   left:201px;
}

.steps li .icon {
   background:url('https://www.java2s.com/style/demo/Google-Chrome.png') no-repeat;
   height:45px;
   width:45px;
}
</style> 
 </head> 
 <body> 
  <ul class="steps"> 
   <li class="step1 first"> 
    <div class="icon basket"></div>Lorem ipsum d</li> 
   <li class="step2"> 
    <div class="icon registration"></div>Lorem ipsum</li> 
   <li class="step3"> 
    <div class="icon payment"></div>Lorem ipsum dol</li> 
   <li class="step4"> 
    <div class="icon order"></div>Lorem ipsum do</li> 
   <li class="step5 last"> 
    <div class="icon thankyou last"></div>Lorem ips</li> 
   <div style="clear:both"></div> 
  </ul>  
 </body>
</html>

Related Tutorials