I am just creating a tab menu with css. I am currently using the code below
[code=html]
<style type=”text/css”>
.main_nav {
list-style: none;
margin-left: 0px;
padding-left: 0px;
}
.main_nav li{
display: inline;
background-color: #34642e;
padding: 0px;
margin: 3px;
}
.main_nav li:hover{
display: inline;
background-color: #ff642e;
margin: 3px;
width: 50px;
}
.main_nav a {
text-decoration: none;
color: #ffffff;
}
.main_nav a:hover {
color: #00ff00;
background-color: #ff642e;
}
.link {
display:inline;
}
.left_top {
background: url(gfx/tl.gif) no-repeat top left;
display: inline;
width: 10px;
}
.right_top {
background: url(gfx/tr.gif) no-repeat top right;
display: inline;
width: 10px;
}
</style>
</head>
<body>
<ul class=”main_nav”>
<li>
<a href=”http://localhost/projects/code/”>
<div class=”left_top”> </div>
<div class=”link”>Home</div>
<div class=”right_top”> </div></a></li>
<li>
<a href=”http://localhost/projects/code/”>
<div class=”left_top”> </div>
<div class=”link”>About Us</div>
<div class=”right_top”> </div></a></li>
<li>
<a href=”http://localhost/projects/code/”>
<div class=”left_top”> </div>
<div class=”link”>Contact Us</div>
<div class=”right_top”> </div></a></li>
</ul>
The main problem I have is as you can see i have a lot of
[code=html]
in my code. The reason for this is that for some reason I can’t set the width or height of the divs which have the class “left_top” and “right_top”.
Any Help??