You can't float something that doesn't have a width because it will just take up 100% of the space. So unless you want to use my example, you'll have to have some sort of logic involved.
<div> <div style="float: right; width: 25%;"> <p>25% div. Collapsible. On the right</p> </div>
<div style="float: left"> <p>This div will be 75% width and to the left of the 25% content. If the first div collapses this div will be 100%</p> </div> </div>
hey, suppose 25% is not there; than another column occupied by 100% itself...
<div> <div style="float: right; width: 25%;"> <p>25% div. Collapsible. On the right</p> </div>
<div style="float: left"> <p>This div will be 75% width and to the left of the 25% content. If the first div collapses this div will be 100%</p> </div> </div>
I want that when the div with 25% collapse, 75% will be enlarged to 100%.
You have to make the 25% one go first in the HTML, but here it is.
i need something like this.
try not floating the first div, but place it after the float div in the markup.
Copy and pasted yours and it works, so clearly I was having a slow morning!
The only way I could do to collapse and was maintained with tables.
you can see the website here (is in spanish), if you want to inspect the code with firebug.
btw, I use joomla.
http://www.tresarroyosweb.com.ar
suppose 25% is not there; than another column occupied by 100% itself...
suppose 25% is not there; than another column occupied by 100% itself...