SitePoint Sponsor

User Tag List

Results 1 to 4 of 4

Hybrid View

  1. #1
    SitePoint Addict vflytrap's Avatar
    Join Date
    Aug 2003
    Location
    Twighlight Zone
    Posts
    206
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Wonky Background Image displaying

    I have a div with a background image - the relevant CSS is:

    #content2 {
    background: #e9e9e9 url(images/bgwatermark.gif) top left fixed no-repeat;
    color: #393939;
    }

    Now for some reason, the background image isn't lining up with the top left in Safari. In IE6/WIN, it works. In Camino for Mac, nothing shows up at all - same with IEMac. Whaaat the hell? Is there a problem with the background image being in a defined div? I can't find anything on compatibility issues, and like I said, it displays right in IE6/WIN which is a miracle of itself.

    To see the file in action you can go to http://www.classicmemories.net/testindex.php
    The stylesheet is saved in the same directory as stylesheet.css

    Can anyone please look at this and tell me if they see something specifically screwing up?

  2. #2
    SitePoint Addict hurricane.uk's Avatar
    Join Date
    May 2003
    Location
    Liverpool
    Posts
    361
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Maybe try 0% 0% instead of top left? I don't have a mac so can't give any definite clues, but it may work

    As far as problems with backgrounds in divs, IE/win has a problem with fixed positioning - it doesn't do it, same for Omniweb/mac which also won't use position or repeat.

    Check here for more:
    http://macedition.com/cb/resources/a...sssupport.html

  3. #3
    SitePoint Wizard Ian Glass's Avatar
    Join Date
    Oct 2001
    Location
    Beyond yonder
    Posts
    2,384
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by hurricane.uk
    As far as problems with backgrounds in divs, IE/win has a problem with fixed positioning - it doesn't do it,
    Probably better to say that IE/Win gets it wrong... (shock)

    The CSS spec. says that fixed positioning positions the background relative to the viewpoint (the whole area displayed by the browser) not the container. You might want to check out css/edge's Complexsptial Demo in IE and then just about any other browser.

    BTW, vflytrap, you probably just want normal positioning. :-)

    ~~Ian

  4. #4
    SitePoint Addict vflytrap's Avatar
    Join Date
    Aug 2003
    Location
    Twighlight Zone
    Posts
    206
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    alright - i'll look into it - thank you!


Bookmarks

Posting Permissions

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