View Full Version : Bg Image problems

02-20-2009, 05:02 AM
I am fairly new to CSS, as well as web building in general. A few years ago I taught myself basic HTML, before the days of XHTML, and now I feel I am lost.

I am reverse-engineering a web page that used background images that was cut into pieces in it's CSS Div Tags. The Tags automatically realigns the pictures, and everything looks fine and dandy on the website.

Now my question is this... Can I add a picture over the top of those pictures in the normal HTML, or what-not. Everytime I try I receive the dreaded X Marks the Square. The background CSS image in this particular area is just white for text over the top, but it will not let me add a picture.

Any help would be greatly appreciated.


02-20-2009, 05:47 AM
Yes, you can add a picture (in an <img> tag) inside a <div> with a background image applied in CSS. Most times the issue you describe has to do with image filepaths.

Do you have a link to your page? We'll need to see all the code.

02-20-2009, 06:23 AM
I appreciate you helping with this problem, and taking a close look at this.

The webpage is:


And the CSS is located at:


02-20-2009, 07:01 AM
Even though I feel rather stupid about the fact that I forgot to upload the picture to my server, hence the reason it wasn't working; I must honestly say that when I did it on my computer it didn't work.

I added the picture on Dreamweaver, and then when I would preview it the picture did not show up even though it was shown in the Dreamweaver window.

Oh well... Atleast it works where it counts.

I still appreciate your help msuffern.

02-20-2009, 02:32 PM

I'm getting a "404 Page not Found" when I click on your links above.

Still sounds like a filepath problem. This post explains (http://codingforums.com/showpost.php?p=784167&postcount=9) how to refer to files in different directories than the files that link to them, both in HTML and CSS.