View Full Version : Non-static DIV layers


Chris
06-07-2006, 09:58 AM
How do I make a DIV layer so that it's not static? ie. when the browser window is resized, the layers move to fit into that size of browser, but don't go anywhere once it becomes too small to fit everything in?

Did I explain that well enough?

Thanks,
Chris

Merike
06-07-2006, 12:19 PM
Correct me if I'm wrong but are you asking this because of your new layout at silenceiseasy.com?

If so then I think I know how to solve it.
In your stylesheet you have:
.main{
width: 560px;
margin-top: 5px;
margin-left: 50px;
}

#sidebar{
width: 300px;
position: absolute;
top: 350px;
right: 50px;
}
But try:
.main{
margin-right: 400px;
margin-top: 5px;
margin-left: 50px;
}

#sidebar{
width: 300px;
position: absolute;
top: 350px;
right: 50px;
}

Chris
06-07-2006, 01:57 PM
Nope, it's not for my personal website :)

Thank you for your help, though.

I figured it out - instead of using exact values (ie. pixels), I used percentages.

Thanks again,
Chris :D