I want a two-column div layout, where each one can have variable width e.g.
div {
float: left;
}
.second {
background: #ccc;
}
<div>Tree</div>
<div class="second">View</div>
I want the 'view' div to expand to the whole width available after 'tree' div has filled needed space. Currently my 'view' div is resized to content it contains It will also be good if both divs take up whole height
Not duplicate disclaimer:
Expand div to max width when float:left is set because there the left one has a fixed width.
Help with div - make div fit the remaining width because I need two columns both aligned to left
Here, this might help...
A slightly different implementation,
Two div panels(content+extra), side by side,
content panel
expands ifextra panel
is not present.jsfiddle: http://jsfiddle.net/qLTMf/1722/
If both of the widths are variable length why don't you calculate the width with some scripting or server side?
<div style="width: <=% getTreeWidth() %>">Tree</div>