Reply
Div Background Image
Old 04-11-2007, 07:21 AM Div Background Image
Extreme Talker

Posts: 202
http://londonlabs.co.uk/test/

I have set a background image for my page using this CSS:
Code:
body {
    background-image: url(images/bg-new.JPG);
    background-repeat: repeat;
    background-color: #00CCFF;
    background-attachment: fixed;
    margin: 0px;
    padding: 0px;
    height:100%;
This image is a small square that is tiled over the whole page.

I have a DIV that has a background image which has been set using this CSS:
Code:
#bg {
    background-image: url(images/splash.gif);
    background-repeat: repeat-x;
    background-attachment: fixed;
    height:600px;
    width: 1990x;
}
This image is the image with the paint splash and bit of text.

In IE6 when I scrol the page down the background image of the bg DIV isnt fixed - I would like it to be.

If FF1.5 the background image of the bg DIV is fixed but when I scrol the background image of the body seems to overlap it.

Is there any way to make the big image that is used by 'bg' fixed but not be covered by the body background image when scrolling down the page?

Thanks.
Joe3000 is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
Old 04-11-2007, 01:38 PM Re: Div Background Image
LadynRed's Avatar
Super Moderator

Posts: 6,570
Location: Tennessee
Quote:
In IE6 when I scrol the page down the background image of the bg DIV isnt fixed - I would like it to be.
Unfortunately, you can't. IE6 does NOT support position: fixed.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!
"Using or working with IE is like having to wear a 1970's polyester suit with pantyhose and a girdle, to work everyday"
Carolina Corvette Club
LadynRed is offline
Reply With Quote
View Public Profile
 
Old 04-12-2007, 05:32 AM Re: Div Background Image
Extreme Talker

Posts: 202
Thats a shame.

Thanks.
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 04-12-2007, 10:24 AM Re: Div Background Image
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,945
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
There is a hack for it (allegedly...I haven't tried it yet):

http://tagsoup.com/cookbook/css/fixed/
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Reply     « Reply to Div Background Image
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.12660 seconds with 12 queries