Images not showing? - Post ID 245395

User 2741647 Photo


Registered User
37 posts

Hello, I added a background image to my html but it's not showing.

Here's what I put:
background-image:url('/desktop/background_image.jpg');

I named it "background_image" and it's a jpg.

What am I doing wrong?
User 187934 Photo


Senior Advisor
18,828 posts

Bring the image into the directory of your project like in a folder named images.
background-image:url('images/background_image.jpg');
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

Here's my S-Drive site with
examples of what can be accomplished in VSD.
https://progrower.coffeecup.com/
Here's my CoffeeCup SCCP Shop with examples of what can be done.
https://progrower.coffeecup.com/shop/
This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 2741647 Photo


Registered User
37 posts

Eric Rohloff wrote:
Bring the image into the directory of your project like in a folder named images.
background-image:url('images/background_image.jpg');

How would I find that folder?
User 271657 Photo


Administrator
3,816 posts

You need to create the folder, then put your images into it.
Please have a read through here:
http://www.coffeecup.com/help/articles/ … ml-editor/
I love deadlines. I like the whooshing sound they make as they fly by. (Douglas Adams)
https://www.callendales.com
User 38401 Photo


Senior Advisor
10,951 posts

The reason you are not getting them to work is because you need to reference the files "as if" they were on the web and right now they are pointed to a location on your own computer. When they are on the web they will not be in a desktop directory so:
    1. Go to the location that your website files are located and see if there is already a folder called images.
    2. If not, then create one there and put your images inside it.
    3. If there is, then put your images inside it.
When you reference them then the location would be:
images/imagename.jpg or .png or ... You hopefully get the picture.

Hope that helps understand what is actually wrong. :)

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.