Child div 100% height to parent auto height

css, html

Solution

By reading your comments on other solutions it is clear to me that only solution for you is to implement some JS into your code. This is not a problem, however.

http://jsfiddle.net/b7TuP/

Problem

Im here because other similar questions couldn't help my particular problem. I need `right div` to be 100% height all the time, where the `parent` height depends on `left div` height which depends on content inside. Here is the html: ``` <div class="container clearfix"> <div class="left"></div> <div class="right"></div> </div> ``` ​Here is CSS: ``` .container{ min-height: 10px; width: auto; height: auto; background-color: #eeeeee; } .left{ position: relative; float: left; min-height: 100px; width: 50px; background-color: #dddddd; } .right{ min-height: 20px; position: relative; float: left; height: 100%; width: 50px; background-color: #dddddd; } . .clearfix:after { content: "."; display: block; clear: both; visibility: hidden; line-height: 0; height: 0; } .clearfix { display: inline-block; } ``` ​Note: I'm using `clearfix`. And if you can show your answer in `jsfiddle` Here is jsFiddle http://jsfiddle.net/C9Kmx/32/

Original source