This question perhaps was asked before, but my case is somehow special.
I have two divs one inside the other. Both divs heights are unknown, but what I can tell about the outer div is its minimal height. The point is - I want the smaller div to center vertically inside the outer div if the inner div is smaller than the outer. And I want the inner div to expand the outer div if it is bigger than the minimal height of the outer div.
I would like to achieve this without using any scripts.
Is it even possible?
Sample code:
<div id="outer" style="min-height:50px;">
<div id="inner">
Im here, I could be short, I could be long
and if I wrap - i could be tall
</div>
</div>