I cant get background images to appear from a css file Here you can see the different …/ combinations Ive used:
background-image: url(“…/images/home-02.jpg”);
background-image: url(“/images/home-02.jpg”);
When the target directoy or file is in the same directory as the CSS the syntax is dot-slash images or just images.
And dot-dot-slash takes you to the parent directory. (The use of just a slash might differ in different OSs)
Edit)
On a web server the use of just a slash takes you to the web site root directory,.
E.g: To target the root index file with the “Home” button you could use just the slash as url “/”.
Yes great to see you are all still here Yes your suggestion worked @Erik_J grazie mille Just to add you spotted I added the wrong image, anyways it works n ow
I’ve concluded that a foolproof way is to use the host file to point the client’s domain to local host in my own machine. That way it doesn’t matter if the URLs are relative or not, though I always use relative paths in URLs.
At least when developing a CMS site you don’t have to search and replace the database for hard-coded URLs before uploading to the live server. (In my experience Wordpress and the like might save absolute URLs where you least expect it.)
If the host file option is impracticable I name the local host domain the same as the live but miss-spell the top level, e.g: .com to .cox to make the search and replace in the databases safe.