I have two divs side by side. I want div that is on left hand side to take up as much room as it needs without pushing the other div (on right) to next line.
Here is what I have right now: http://jsfiddle.net/RALza/
HTML
<div id="container">
<div id="divA"> left text </div>
<div id="divB"> right text </div>
</div>
CSS
#divA
{
float:left;
border:1px solid blue;
width:100%;
}
#divB
{
float:right;
border:1px solid red;
}
will work.
But you should specify width of floating elements.