Case
06-28-2007, 03:33 PM
Hello all,
I am trying to have a div be set to the height of it's containing div, that has an absolute location, it's not working. :(
CSS
#page_content_container{
width:100%;
background-color:#009966;
}
#page_content_column{
position:relative;
width:900px;
margin:auto;
background-color:#FF0000;
}
#detail_content_column_one{
position:absolute;
left:0;
width:550px;
padding-left:5px;
background-color:#00CC66;
}
/*for illustration purposes only*/
#detail_content_column_two{
width:550px;
padding-left:5px;
background-color:#00CC66;
}
HTML
<!--Example1-->
<div id="page_content_container">
<div id="page_content_column">
<div id="detail_content_column_one">
<div>
<p>I wanna cry</p>
<p>sadfasdfsd</p>
<p>asdfsda</p>
<p>asdf</p>
</div>
</div>
</div>
</div>
<!--End of example1-->
<div style="height:200px;"></div>
<!--Example 2-->
<div id="page_content_container">
<div id="page_content_column">
<div>
<p>I wanna cry</p>
<p>sadfasdfsd</p>
<p>asdfsda</p>
<p>asdf</p>
</div>
</div>
</div>
<!--End of example2-->
<div style="height:200px;"></div>
<!--Example 3-->
<div id="page_content_container">
<div id="page_content_column">
<div id="detail_content_column_two">
<div>
<p>I wanna cry</p>
<p>sadfasdfsd</p>
<p>asdfsda</p>
<p>asdf</p>
</div>
</div>
</div>
</div>
<!--End of example3-->
The Link: http://www.mooseblood.com/shoot.html shows
Example #1 shows the code with the absolute and relative block not working at all it doesn't have any colors behind it. (thus no expanding divs)
Example #2 shows the code with NO #detail_content_column_one (or absolute positioned div) and thus shows the 2 columns that should expand with #detail_content_column_one.
Example #3 shows the code with #detail_content_column_one (actually #detail_content_column_two) without being absolutely positioned, and thus, it working correctly.
I would LOVE any help with this, as I am coming to the end of my rope
I am trying to have a div be set to the height of it's containing div, that has an absolute location, it's not working. :(
CSS
#page_content_container{
width:100%;
background-color:#009966;
}
#page_content_column{
position:relative;
width:900px;
margin:auto;
background-color:#FF0000;
}
#detail_content_column_one{
position:absolute;
left:0;
width:550px;
padding-left:5px;
background-color:#00CC66;
}
/*for illustration purposes only*/
#detail_content_column_two{
width:550px;
padding-left:5px;
background-color:#00CC66;
}
HTML
<!--Example1-->
<div id="page_content_container">
<div id="page_content_column">
<div id="detail_content_column_one">
<div>
<p>I wanna cry</p>
<p>sadfasdfsd</p>
<p>asdfsda</p>
<p>asdf</p>
</div>
</div>
</div>
</div>
<!--End of example1-->
<div style="height:200px;"></div>
<!--Example 2-->
<div id="page_content_container">
<div id="page_content_column">
<div>
<p>I wanna cry</p>
<p>sadfasdfsd</p>
<p>asdfsda</p>
<p>asdf</p>
</div>
</div>
</div>
<!--End of example2-->
<div style="height:200px;"></div>
<!--Example 3-->
<div id="page_content_container">
<div id="page_content_column">
<div id="detail_content_column_two">
<div>
<p>I wanna cry</p>
<p>sadfasdfsd</p>
<p>asdfsda</p>
<p>asdf</p>
</div>
</div>
</div>
</div>
<!--End of example3-->
The Link: http://www.mooseblood.com/shoot.html shows
Example #1 shows the code with the absolute and relative block not working at all it doesn't have any colors behind it. (thus no expanding divs)
Example #2 shows the code with NO #detail_content_column_one (or absolute positioned div) and thus shows the 2 columns that should expand with #detail_content_column_one.
Example #3 shows the code with #detail_content_column_one (actually #detail_content_column_two) without being absolutely positioned, and thus, it working correctly.
I would LOVE any help with this, as I am coming to the end of my rope