Help - Search - Members - Calendar
Full Version: Question about DIV
Movable Type Community Forum > Additional Resources > Tips and Tricks
YP Geek
I've got my BANNER, CONTENT, and LINKS all in one DIV called "PAGE" and the PAGE DIV has a full border.

The PAGE DIV will run as long as the LINKS DIV does, but cuts off after that, causing my CONTENT DIV to spill outside of the PAGE border.

My question is how do I keep it contained, or how do I make the PAGE DIV extend with the CONTENT as well?

If I need to post my CSS Code, I will.

Thanks in advance!

http://www.andythegeek.com/
adamrice
You don't need to post the CSS here. We know where it lives.

I'm not sure about this, but I think the problem may be that you have an absolute-positioned element (content div) inside an unpositioned element (page div). Like a person that tells you way too much about his personal life, the contained element in this situation doesn't respect boundaries. By applying some--any--positioning to the containing element here, you can put the contained element back in its place, respecting boundaries.

Also, I don't think the content div needs absolute positioning anyhow to achieve this effect, but try either of the following.

Add the line "position: relative;" to the #page style.

Delete the line "position: absolute;" from the #content style.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.