Reputation: 13
I am having some trouble with the navigation bar for my website. I have created the nav bar using lists and CSS styling. The clickable boxes that are on the bar stay small and relative to the size of the contents within that box but I want it to be a set size.
#navbar ul, #navbar ul li {padding:0; margin:0; list-style:none; }
#navbar a{color:#FFFFFF; font-weight:bold;}
#navbar a:hover{background:#777777;}
#navbar li a:link, #navbar li a:visited {background:#444444; text-decoration:none; height:24px; line-height:24px; display:inline; float:left; width:auto; padding:0px 10px;}
This is the CSS that I am using for the nav bar.
Upvotes: 1
Views: 804
Reputation: 744
Try setting:
display:block;
on your anchor tag, combined with some padding to bring the styling away from the text?
Upvotes: 1