View Full Version : Help with div background image
11-26-2008, 05:00 PM
Here's my CSS code
border-bottom: 2px solid black;
In my HTML file I've created the header div, but the image won't show up in FF or IE. The path to the file is correct, what could be causing this?
11-26-2008, 05:17 PM
Try replacing all those background lines with this:
background: #000000 url(images/hdr-bkg.png) repeat-x;
Change the #000000 color or remove it, it's only black because I don't know what fucia is.
11-26-2008, 05:18 PM
Where is your CSS file located relative to the image file, though? If you're linking to an external stylesheet from your HTML file like so:
<link href="css/main.css" rel="stylesheet" type="text/css"/>
then your CSS file is up one directory level (/css) relative to the HTML file, so in referencing the background image, you'll need to tell the CSS file to go back down one level:
If that doesn't fix it post your whole code (HTML and CSS).
11-26-2008, 05:51 PM
Both suggestions helped the ../ post fixed the image not showing, but the other post helped consolidate my code. Thanks!!
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.