How can I position my div at the bottom of its container?

前端 未结 24 2436
广开言路
广开言路 2020-11-22 00:46

Given the following HTML:



        
24条回答
  •  广开言路
    2020-11-22 01:35

    Div of style, position:absolute;bottom:5px;width:100%; is working, But it required more scrollup situation.

    window.onscroll = function() {
        var v = document.getElementById("copyright");
        v.style.position = "fixed";
        v.style.bottom = "5px";
    }
    

提交回复
热议问题