2 divs aligned side by side, how to make right div fill width 100%?

前端 未结 8 1059
遥遥无期
遥遥无期 2021-01-31 08:17

I\'m wondering what the best way to go about doing this is...

I have 3 divs:

  • a div#container with width=100%; tha

8条回答
  •  孤独总比滥情好
    2021-01-31 08:42

    This is based on @w00 's answer. +1 friend.

    My situation was when I wanted to show a couple of icons next to a label. I use the fluid class for that which is where the nowrap comes in. This is so the icons appear on the same line.

    .sidebyside-left-fixed, .sidebyside-right-fixed
    {
        display: table-cell;
        width: 100%;
    }
    
    .sidebyside-left-fluid , .sidebyside-right-fluid
    {
        display: table-cell;
        vertical-align: top;
        white-space: nowrap;
    }
    

提交回复
热议问题