Can't set background image in CSS

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Can't set background image in CSS

Magni
hey,
I want to put this image http://images.alphacoders.com/112/112321.jpg  as my background on the CSS sheet  for my forum  
but it's not working :/
Can anyone please help me?

Grtz,
Magni
Reply | Threaded
Open this post in threaded view
|

Re: Can't set background image in CSS

GregChapman
It's always a good idea to tell us the URL of the forum in question (helps to know if it's embedded or not, whether there is other code that may cause a conflict etc) and, in this case, what the CSS code is that you are currently using.

This line represents a start, but there are potential problems with it:

.nabble {background-image: url(http://images.alphacoders.com/112/112321.jpg);}

However, I would strongly recommend that you change your plan. Background images, should be just that - background. This is a fully fledged image of great impact and deserves to have time spent looking at it. It will distract your visitors from reading your forum. Leaving aside the artistic merits of the image there are technical ones.

# I trust you have the rights to use it, if it is copyright

# The image is large. At 369,897 bytes, it will take a significant time to download, especially on dialup and other slow connections.

# Large images, such as this, do not display well on screens of a different size to yours, either being truncated or repeating, destroying the composition and point of the image.

# The intense contrast in the image from near black to near white means that it will be impossible to select a colour for your text that will display well against all parts of the image, making much of your forum impossible to read.

In general, you should use small images for any background, perhaps using some of these techniques:
# Allow them to repeat vertically or horizontally
# Using an image that can be made to fade to a toning background colour
# Set them to display round the edges of the main content of the page

Hope this helps!
Volunteer Helper - but recommending that users move off the platform!
Once the admin for GregHelp now deleted.