Alfred wrote:[color=blue]
> I essentially have the standard two column layout, but I'm running
> into a quirk I'm hoping someone can help with. I have one column
> which is the main content (75%) of the screen and the remaining 25% is
> reserved for "side" content.
>
> The problem with my CSS is that if the main content's height is less
> than the side content's height, the side content will wrap underneath
> the main content instead of staying within the 25% bounds.[/color]
[snip]
The "classic" answer to keeping things in columns is to give the non-floated
element a large margin on the side of the floated element. The margin should
be at least as wide as the width of the floated element.
The same technique works for avoiding superimposing onto absolutely-positioned
elements too, if you used that instead of float.
This "large margin" approach actually has a specific problem in the case of
floats, although I suspect that it won't matter much to you. If the viewport
becomes so narrow that the non-floated element drops below the floated one,
the non-floated element will still have that, now-inappropriate, large margin.
You need to experiment to see if it matter to you.
--
Barry Pearson
http://www.Barry.Pearson.name/photography/ http://www.BirdsAndAnimals.info/ http://www.ChildSupportAnalysis.co.uk/