How To Auto Set The Height Of A Div Using The Height Of Another Div
I have another question about css auto sizing content. I have three divs next to eachother that all need to be the same lenght, but that length is set by the longest div, and not
Solution 1:
Maybe its possible with display: table.
CSS:
#content {
width: 100%;
height: 100%;
padding: 0;
margin: 0;
display: table;
}
#bodyContent {
display: table-cell;
float: none;
width: auto;
height: 100%;
background: #FFC273;
}
#bodySideBar {
display: table-cell;
width: 50px;
height: 100%;
background: #BF8130;
}
#bodyUpdateBar {
display: table-cell;
width: 200px;
background: #FFCA40;
}
HTML:
<divid="content"><divid="bodySideBar">a
<br><br><br>b</div><divid="bodyUpdateBar">a
<br><br><br><br><br><br><br><br><br>b</div><divid="bodyContent">a
<br><br><br><br><br><br>b</div></div>
Post a Comment for "How To Auto Set The Height Of A Div Using The Height Of Another Div"