skmathunny
11-07-2008, 11:45 PM
Hi,
html and css newbie here. This issue is as follows:
<body>
<div style="background-color: Red; width: 400px; height: 100px" onclick="javascript:does(this);"></div>
<div id="div1" style="position:absolute; bottom: 0; background-color: Green; width: 400px; top: 100px; min-height: 100px"></div>
</body>
I would like div1 to take the space left over when you click on the first div. Currently the second div stays in place. I would like it expand upwards to fill the space left by the first div. I know I can do this using javascript. But is there is a way to do this without javascript, just with html and css.
Thx
Sam
html and css newbie here. This issue is as follows:
<body>
<div style="background-color: Red; width: 400px; height: 100px" onclick="javascript:does(this);"></div>
<div id="div1" style="position:absolute; bottom: 0; background-color: Green; width: 400px; top: 100px; min-height: 100px"></div>
</body>
I would like div1 to take the space left over when you click on the first div. Currently the second div stays in place. I would like it expand upwards to fill the space left by the first div. I know I can do this using javascript. But is there is a way to do this without javascript, just with html and css.
Thx
Sam