How do I get a floating footer to stick to the bottom of the viewport in IE 6?

前端 未结 6 1860
感动是毒
感动是毒 2020-12-03 08:14

I know this would be easy with position:fixed, but unfortanately I\'m stuck with supporting IE 6. How can I do this? I would rather use CSS to be clean, but if I have to u

6条回答
  •  隐瞒了意图╮
    2020-12-03 08:58

    I have done this using CSS expressions in the Past.

    Try something like this:

    .footer {
        position: absolute;
        top: expression((document.body.clientHeight - myFooterheight) + "px");
    }
    

    read more here
    and here

提交回复
热议问题