batch
02-11-2005, 12:14 AM
Here's the code:
<style type="text/css">
#lifecontainer {
position:relative;
background-image: url(images/bg_paper.gif);
background-repeat: repeat;
width:700px;
z-index:0;
}
#blog {
position:relative;
background-image: url(images/header_latest.gif);
background-repeat: no-repeat;
width:350px;
padding-top:52;
z-index:1;
}
#sidebar {
position:relative;
background-image: url(images/bg_sidebar.gif);
background-repeat: repeat;
top:0;
left: 375px;
width:213px;
z-index:2;
}
</style>
</head>
<body>
<div id="lifecontainer">
<div id="blog">TEST</div>
<div id="sidebar">
<div id="profile">TEST</div>
</div>
</div>
</body>
Here's the problem:
Even though the layer SIDEBAR is on it's own Z-level, it is getting pushed down by the BLOG layer. I want BLOG, and SIDEBAR to sit within LIFECONTAINER. BLOG on the left and SIDEBAR to the right, and both of them at the very top. The only way I have been able to achieve this so far is to absolute position the SIDEBAR layer. but that causes problems as I want LIFECONTAINER to have a repeating background image that will sit under all the layers and contain them, stretching verticaly as needed. SO aboslute positioning of SIDEBAR results in it sitting outside of the LIFECONTAINER layer. I don't ever remember an instance of DIV's acting like inline elements?
thanks in advance folks...
<style type="text/css">
#lifecontainer {
position:relative;
background-image: url(images/bg_paper.gif);
background-repeat: repeat;
width:700px;
z-index:0;
}
#blog {
position:relative;
background-image: url(images/header_latest.gif);
background-repeat: no-repeat;
width:350px;
padding-top:52;
z-index:1;
}
#sidebar {
position:relative;
background-image: url(images/bg_sidebar.gif);
background-repeat: repeat;
top:0;
left: 375px;
width:213px;
z-index:2;
}
</style>
</head>
<body>
<div id="lifecontainer">
<div id="blog">TEST</div>
<div id="sidebar">
<div id="profile">TEST</div>
</div>
</div>
</body>
Here's the problem:
Even though the layer SIDEBAR is on it's own Z-level, it is getting pushed down by the BLOG layer. I want BLOG, and SIDEBAR to sit within LIFECONTAINER. BLOG on the left and SIDEBAR to the right, and both of them at the very top. The only way I have been able to achieve this so far is to absolute position the SIDEBAR layer. but that causes problems as I want LIFECONTAINER to have a repeating background image that will sit under all the layers and contain them, stretching verticaly as needed. SO aboslute positioning of SIDEBAR results in it sitting outside of the LIFECONTAINER layer. I don't ever remember an instance of DIV's acting like inline elements?
thanks in advance folks...