Can you relativlely or absolutely position items in a display:table-cell?

后端 未结 3 564
不知归路
不知归路 2021-01-27 07:51

I have a link that I want to always be at the bottom right of the cell it is in. Right now the link is in a < p > element. I tried doing both absolutely and relative position

3条回答
  •  被撕碎了的回忆
    2021-01-27 08:11

    Edited: Sorry..!! Missed it :). As said by ahsaan, Add position relative to .layout-cell and modify your HTML as below.

     .layout-cell {
        display: table-cell;
        vertical-align: top;
        position: relative;
     }
    
     .layout-cell div{
       position:absolute;
       bottom:0;
       right:0;
      }
    
    

    Column 3

提交回复
热议问题