Footer at bottom of browser except when I scroll

前端 未结 2 1627
情书的邮戳
情书的邮戳 2021-01-19 06:36

I\'m having a weird footer issue.

http://jsfiddle.net/YGAvd/

The clouds at the bottom of the page will stick to the bottom of the browser window if I expand

2条回答
  •  遇见更好的自我
    2021-01-19 07:00

    In the footer CSS rule change 'position: absolute;' to 'position: fixed;'

    you may also have to play with a few other def's but this works.

    check it out

    Here is my final footer rule

    footer {
        position: fixed;
        color: black;
        width: 100%;
        height: 4.6em;
        background-image: url(http://img.photobucket.com/albums/v410/justice4all_quiet/bottom_clouds.jpg);
        background-repeat: repeat-x;
        background-color: e0e0e0;
        z-index: -999;
        overflow: hidden;
        bottom: 0px;
    }
    

提交回复
热议问题