LI padding: .3em 0 : li padding « Tags « HTML / CSS






LI padding: .3em 0

    
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<style type="text/css">
li {
 border-top: 1px solid black;
 padding: .3em 0;
}

ul {
 margin-left: 40px;
 padding-left: 0px;
 border-bottom: 1px solid black; 
 list-style: none;
 width: 36%;
}
</style>
</head>

<body>
    <ul>
    <li>V</li> 
    <li>S</li>
    <li>T</li> 
    <li>P</li> 
    </ul>

</body>
</html>

   
    
    
  








Related examples in the same category

1.Using padding to control the list item indent
2.li padding: .3em 0 1em 40px;
3.ol, ul {margin-left: 0; padding-left: 2.5em;}