CSS tab based navigational bar : Navigation Bar « CSS Controls « HTML / CSS






CSS tab based navigational bar

  

<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title></title>
    <style type="text/css">
#navsite h5 {
  display: none;
}

#navsite ul {
  padding: 3px 0;
  margin-left: 0;
  border-bottom: 1px solid #669;
}

#navsite ul li {
  list-style: none;
  margin: 0;
  display: inline;
}

#navsite ul li a {
  padding: 3px 0.5em;
  margin-left: 3px;
  border: 1px solid #669;
  border-bottom: none;
  background: #ccf;
  text-decoration: none;
}

#navsite ul li a:link {
  color: #339;
}

#navsite ul li a:visited {
  color: #666;
}

#navsite ul li a:link:hover, #navsite ul li a:visited:hover {
  color: #000;
  background: #AAE;
  border-color: #336;
}

#navsite ul li a#current {
  background: white;
  border-bottom: 1px solid white;
}
    </style>
  </head>
  <body>
  <div id="navsite">
  <ul>
   <li><a href="http://www.java2s.com">Home</a></li>
   <li><a href="http://www.java2s.com">Home</a></li>
   <li><a href="http://www.java2s.com">Home</a></li>
    <li><a href="http://www.java2s.com">Home</a></li>
   <li><a href="http://www.java2s.com" id="current">Home</a></li>
   <li><a href="http://www.java2s.com">Home</a></li>
  </ul>
  </div>
  </body>
 </html>

   
  








Related examples in the same category

1.Left navigation bar
2.One column with top navigation bar
3.Right navigation bar
4.Left bar menu
5.Horizontal menu
6.Expandable left bar
7.Nested List style
8.Styled tab navigation
9.Negative Margins example
10.Horizontal navigation bar with anchor and list
11.Horizontal menu with list
12.Using image only as the top navigation bar
13.Vertical Navigation
14.Horizontal Navigation
15.Highlight top navigation link when mouse hover
16.Links navigation at the bottom
17.One level top navigation bar
18.Navigation bar with selected item
19.Horizontal Nav