www.webdeveloper.com
Results 1 to 5 of 5

Thread: background:fixed; problem

  1. #1
    Join Date
    Nov 2002
    Posts
    631

    background:fixed; problem

    I have a page which uses:

    body {
    background:url("pattern.gif") fixed;
    background-color:#008800;
    margin:0px;
    }

    It works fine. Then I have another page which has EXACTLY the same thing. I have even checked over it like a thousand times, character for character. I even copy and pasted it from the original site. THE BACKGROUND ISN'T FIXED! What is wrong? I am displaying the page I want a fixed background on in an iframe. Could that have anything to do with it?

  2. #2
    Join Date
    Nov 2002
    Location
    NY, USA
    Posts
    731
    You havn't really told us anything more than "it should work but it doesn't." Where is the page that doesn't work? Otherwise my guess (from many many possibilities) is that the background-attachment gets redefined later in the cascade.

  3. #3
    Join Date
    Feb 2003
    Location
    Michigan, USA
    Posts
    5,774

  4. #4
    Join Date
    Jan 2003
    Location
    Atlanta, GA
    Posts
    571
    Or maybe this
    Code:
    body { 
    background: #080 url(patern.gif) fixed; 
    margin:0px; 
    }
    To prevent tiling:
    Code:
    body { 
    background: #080 url(patern.gif) no-repeat fixed; 
    margin:0px; 
    }

  5. #5
    Join Date
    Nov 2002
    Posts
    631
    Thanx for the help. I will try them.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles