Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Problems with a sticky footer

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #40637
    BranCook
    Participant

    Having some issues with a div stretching to 100% height using a sticky footer. I’m trying to get the div “content-wrap” to stretch down to the footer but it’s not working. given that it’s parent or containing div is also set to 100% shouldn’t it stretch down to the sticky footer?

    [sample on jsfiddle](http://jsfiddle.net/QsWAk/ “view sample on jsFiddle”)

    #113461
    elneco
    Participant

    http://jsfiddle.net/QsWAk/1/

    .wrap is already the full height of the window. If you want the grey area to stretch down to the green footer you will need to calculate the space the grey box takes up of the screen (in percentages – not all screens are the same) this in addition to the height of the blue header.
    basically its:
    header + contentwrap + footer = 100%

    but all of this defeats the purpose of your stickfooter…..

    #113483
    BranCook
    Participant

    Yeah, I could put the background color on the .wrap div but I can’t figure out a way to get that to work with my design. May need to rethink the structure.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘CSS’ is closed to new topics and replies.