Horizontal menu using list and css - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Menu

Description

Horizontal menu using list and css

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">
ul.nav {<!--   w w w  .j  a  va 2s .  co  m-->
   margin:0;
   padding:0;
   list-style-type:none;
}

ul.nav li {
   margin:0;
   display:inline;
}

ul.nav li a {
   text-decoration:none;
}

ul.nav li a:hover {
   color:Chartreuse;
}

ul.nav li:after {
   content:" | ";
}

ul.nav li:last-child:after {
   content:"";
}
</style> 
 </head> 
 <body> 
  <ul class="nav"> 
   <li> <a href="#">Lorem ipsum</a> </li> 
   <li> <a href="#">Lorem ipsum</a> </li> 
   <li> <a href="#">Lorem ipsum</a> </li> 
   <li> <a href="#">Lorem ipsum</a> </li> 
   <li> <a href="#">Lorem ipsum</a> </li> 
  </ul>  
 </body>
</html>

Related Tutorials