|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Two backgrounds for the body tag
At the moment, my BODY tag contains the following CSS:
Code:
BODY {
background: url(images/gradients/bg_top.jpg);
background-repeat: repeat-x;
}
The bg_top.jpg file is an image 200px high, and 3px wide. This displays nicely at the top of my page. It is a gradient from dark grey which fades out to a pattern of simple squares. I would then like these squares to be repeated across the whole of my background. What I wanted to do was to set a second background image that would display underneath the gradient, but this didn't appear to work. Looking around Google, it appears that you can only set the one background for the body tag. Is this the case? If so, is it possible to set it up so that the square pattern repeats itself across the whole page, but underneath the gradient at the top? Many thanks. |
|
#2
|
||||
|
||||
|
Only one background-image per customer, thank you. Pay on the way out.
The quick, obvious solution is to extend your pattern vertically another ??px to allow for the largest body-size you're likely to have. You could also use a banner container across the top that has your grad.png background. Create another small image of the square pattern only to tile as the body background. The banner background would overlay the body background at the top of the page, and the body background would show lower down. cheers, gary
__________________
There are those who manage to build a web site without knowing what they're doing; thereby proving to themselves they do, indeed, know what they're doing. My html and css workshop, demos and tutorials. Ask a better question, get a better answer. |
|
#3
|
||||
|
||||
|
Quote:
I had thought about that, but I don't know what size the pages are, because most of them are dynamic. Quote:
This is what I decided to do in the end thanks. I set the body background to the small square pattern, then created a new table which covered the whole page with the gradient image. Thanks for your help. |
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > Two backgrounds for the body tag |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|