One column with top navigation bar : Navigation Bar « CSS Controls « HTML / CSS






One column with top navigation bar

  


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <title>CSS Positioning Example</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  <style rel="stylesheet" type="text/css">
div {
  width: 800px;
  border: 1px solid #000;
  margin: 1px;
  padding: 5px;
}

div#masthead {
  height: 100px;
  background-color: #d6d;
}

div#navigation {
  height: 40px;
  background-color: #666;
  color: #fff;
}

div#body {
  height: 100%;
  background-color: #fff;
}
</style>
</head>

<body>
  <div id="masthead"><h1>Masthead</h1></div>
  <div id="navigation">
    <span class="navItem">Navigation item 1</span> | 
    <span class="navItem">Navigation item 2</span> | 
    <span class="navItem">Navigation item 3</span> | 
    <span class="navItem">Navigation item 4</span>
  </div>
  <div id="body"><h1>Headline</h1><p>Article goes here</p></div>
</body>

</html>

   
  








Related examples in the same category

1.Left navigation bar
2.Right navigation bar
3.Left bar menu
4.Horizontal menu
5.Expandable left bar
6.CSS tab based navigational 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