Posted by Ben C on 10/29/06 15:11
On 2006-10-28, windandwaves <nfrancken@gmail.com> wrote:
> Hi Folk
>
> Can you do vertical-align bottom in a div or only really in a table?
You can set it on inline level elements to move them relative to the
line they're on. But if you want the effect of a box with a set height
that contains another box at the bottom of it, use positioning. Set the
outer box to position: relative (or position: absolute), and the inner
box to position: absolute with bottom: 0px.
You set position on the outer box just to make it the containing block
for the inner box (i.e. the block the inner box is 0px from the bottom
of).
Using relative rather than absolute on the outer box keeps it "in the
normal flow".
Navigation:
[Reply to this message]
|