SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Addict
    Join Date
    Aug 2006
    Posts
    288
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    background on the HTML element?

    I need a container to place a background and all the available ones are taken.

    I was about to create another div just to hold that background but then I thought of the HTML element. It seems that Firefox 2, IE6 and 7 recognize background on HTML while IE5 does not. I don't really care about IE prior of version 6, however I don't know if other browsers (Safari, Opera etc) support background on HTML or not.

  2. #2
    SitePoint Guru
    Join Date
    Mar 2004
    Location
    Earth
    Posts
    406
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    They all do, it's only IE5 that doesn't.

  3. #3
    SitePoint Zealot Shpook's Avatar
    Join Date
    May 2007
    Location
    Hollywood, FL, USA
    Posts
    129
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Why not just place a background on the <body> element? And if that one is taken, just create another <div> to wrap everything and apply the background there. There's nothing wrong with doing it that way.
    Life would be so much easier if we
    could just look at the source code.
    -Dave Olson

  4. #4
    SitePoint Wizard silver trophybronze trophy Nadia P's Avatar
    Join Date
    Oct 2004
    Location
    NSW Australia
    Posts
    3,564
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    To be on the safe side for cross platform/browser compatibility, I'd wrap a new div around your whole layout and place the background image on that :-)

    Nadia

  5. #5
    SitePoint Addict
    Join Date
    Aug 2006
    Posts
    288
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for your answers


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
  •