I want to align the DIV c
in the bottom of the DIV b
not DIV a
<div id="a">
<div id="b">
<div id="c">
Div c
</div>
</div>
</div>
This should work:
#b {
position: relative;
}
#c {
position: absolute;
bottom: 0px;
}
The trick is position: relative;
on the parent element. Without that, #c
will float away to the bottom of the page.
It will take div#c
out of the flow of the document. It may not be perfect, but you can do something like the following:
#b {
position: relative;
}
#c {
position: absolute;
bottom: 0;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With