Floated Divs Obeying/Not Obeying Vertical-Align

后端 未结 5 990
佛祖请我去吃肉
佛祖请我去吃肉 2021-02-09 20:00

Within a table cell that is vertical-align:bottom, I have one or two divs. Each div is floated right.
Supposedly, the divs should not align to the bottom, but they do (whic

5条回答
  •  独厮守ぢ
    2021-02-09 20:24

    I never answered the first two questions, so feel free to give your answers below. But I did solve the last problem, of how to make it work.

    I added a containing div to the two divs inside the table cells like so:

    Then I used the following CSS

    
    

    The key to it all is for a div to be position absolutely relative to it's parent the parent must be declared position:relative

    提交回复
    热议问题
    Title Text
    Line 2
    @