I have the following markup
<div id="hearingSummary">
<table class="minit开发者_StackOverflowable">
... content removed for brevity
</table>
<div>
<div class="pagination">
<span class="paginationLeft">left text</span>
<span class="paginationRight">right text</span>
</div>
</div>
</div>
Classes .paginationLeft
and .paginationRight
have the following CSS associated
.paginationLeft
{
float:left;
}
.paginationRight
{
float: right;
}
I wish to position absolutely the DIV that contains the pagination element to be always at the bottom of its container so I changed it to
<div style="position:absolute; bottom: 3px;">
<div class="pagination">
<span class="paginationLeft">left text</span>
<span class="paginationRight">right text</span>
</div>
</div>
But the SPAN
elements now does not float as specified in the CSS classes. What is the best way to solve this?
You need to give your absolute positioned element a width.
精彩评论