SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    Sep 2008
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Angry How to stop body text from 'scrolling' over ('in front of') a fixed header

    I have set up a fixed header but when I use the scroll bar to move the body text, the top rows of text move 'in front of' the header. I want the text to disappear 'behind' the header so that the header's appearance does not change. How? Here is my latest unsuccessful attempt:

    #header {
    left: 150px;
    right: 3px;
    border-top: 3px solid #7da5d8;
    }

    @media screen{
    body>div#header{
    position: fixed;
    }

    }
    * html body{
    overflow:hidden;
    }

  2. #2
    SitePoint Zealot
    Join Date
    Jul 2008
    Posts
    188
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Take a look at the z-index attribute. The below article explains it quite well.

    http://css-discuss.incutio.com/?page...ppingAndZIndex

  3. #3
    SitePoint Member
    Join Date
    Sep 2008
    Posts
    10
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I have just found the time to read your reply and test it. Your answer worked briiliantly!

    Allan


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
  •