CSS background-image problems

Im not sure what I am doing wrong. I am trying to add a background image to the website I am working on and its not working correctly. I have watched videos and it looks like I am doing everything ok. I have the image as a jpeg and I also tried it as a GIF.

This is what I used… am I doing something wrong and if not how should I troubleshoot this?

body {
background-image: url(“images/ckw.gif”);}

Well, for all i know you forgot a closing curly bracket somewhere, the only way for me to troubleshoot is your full css code (and the image), what is not working correctly?

Try putting the image in the same folder as the html file and then just have ckw.jpg instead of images/ckw.jpg ? I would need to see your code, as @stetim94 stated.

Why? Having the images in a subdirectory works fine

I don’t know, I just prefer to have everything in one place. Personal preference.

If projects get bigger (webapp with rails for example), i would organize it differently. Anyway, we are going off topic

1 Like