Hi everyone

I was using this CSS template for my site but when I tried to add a background to the navbar the picture only appeared in between the links not behind them. I have tried removing the hover and a:link and a: visited but it doesnt make any difference. Can someone help me out please I tried placing the code where the comment is

body {color: #000; background-color: #FFF}
body, p {font: 11px/14px verdana, geneva, arial, helvetica, sans-serif}

h1 {font: 24px "trebuchet ms", verdana, arial, helvetica, geneva, sans-serif}
h2 {font: 20px "trebuchet ms", verdana, arial, helvetica, geneva, sans-serif}
h4 {font: 18px geneva, sans-serif; margin: 0; color: #000; background-color: #FFF}
a {text-decoration: none}

div#navbar {width: 130px; float: left}
div#navbar a {display:block; margin: 0}
div#navbar a:link, a:visited  {color: #000}
div#navbar a:hover {color: #FFF; background-color: #008000}
*/ I tried placing the code here */


div#main {width: 80%; float:right}

#signature{font: 17px "Bradley Hand ITC"}

div#footer {border-color: gray; border-width: 2px 0px 0px 0px; border-style: solid; color: gray; padding: 6px 0px 10px 0px; display: block; float: none; clear: both; margin: 20px 0px 0px 0px}

li {margin-bottom: 10px}

Many Thanks
HLA91

I need to see your html.

Try the following:

1. You must define the background image in the stylesheet, not in the html, if you have styles applied to the navbar. Otherwise, ALL of the "navbar" styles you have will trump your image in importance.

2. What kind of object contains the navbar? Certain objects are not transparent to images.

3. Your change of the background color on hover might not be reversible to display an image again. There is no transparent attribute for background.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.