How can I send an inner
to the bottom of its parent
?

前端 未结 8 736
执念已碎
执念已碎 2020-11-30 17:25

The div inside another div picture and code below. Because there will be text and images of the parent div. And red div will be the last element of the parent div.

<

8条回答
  •  囚心锁ツ
    2020-11-30 17:59

    This is one way

    But because the inner div is positioned absolutely, you'll always have to worry about other content in the outer div overlapping it (and you'll always have to set fixed heights).

    If you can do it, it's better to make that inner div the last DOM object in your outer div and have it set to "clear: both".

提交回复
热议问题