Force sidebar height 100% using CSS (with a sticky bottom image)?

后端 未结 15 1270
再見小時候
再見小時候 2020-12-02 05:40

I\'ve been banging my head against the wall for hours trying to figure out this issue and think it must be something small I\'m missing. I\'ve searched online, but nothing

15条回答
  •  星月不相逢
    2020-12-02 06:39

    I realise this is an old post but I was trying to work something out for my site to have a sidebar. Would this work?

    #sidebar-background
    {
        position:fixed;
        width:250px;
        top:0;
        bottom:0;
        background-color:orange;
    }
    
    #content-background
    {
        position:fixed;
        right:0;
        top:0;
        bottom:0;
        left:250px;
        background-color:pink;
    }
    
    #sidebar
    {
        float:left;
        width:250px;
    }
    
    #content
    {
        float:left;
        width:600px;
    }
    
    
    
    Stuff in here

提交回复
热议问题