D Ross wrote:
> Hmmm - I added floats to the sidebar and the mainContent divs and
> removed the abs. positioning but now the wrapper isnt expanding with
> them....I just dont understand floats well enough yet and need to do
> more research and reading about them...
Floats - as everything in CSS - have a steep learning curve. Floats are
the new "tables" for design IMO, and I'm in the process of un-nesting
some of the more extreme uses of them. There can be too much floating in
a web page, but I find it hard to do without them.
I advice everyone who'd like to understand floats, to read this article:
.... a few times, *and* try it out at home.
The fact that we don't need negative margins all that often, doesn't
matter here. The article is extremely useful for basic understanding of
how floats works.
To make an outer container expand and wrap: simply put <br style="clear:
both;" /> just above the closing </div> in that container - wrapper in
your case. That's the basic clearing needed. More about clearers here:
Once you've got the hang of it, you may try out the clearing-methods on
You may also simply float the entire wrapper. Floating containers will
expand to contain other floats, but it takes a bit if trial and error to
make floats act as the nearly perfect positioning-tools they are. Add a
bit of "non-float" understanding to it, and "a sweet little floating web
page" may be created "on demand" - across browser-land.
To add to an earlier explanation on this list: floats can go in and out
of the flow, and act partly as an in-flow element and partly as an
absolute positioning element - at the same time - without being either.
Guess I'll have to spell it out, with a few examples, as soon as I can
find the time.
Absolute positioning isn't "out" in any way. AP elements can use floats
as base, and even the other way around. That way we may create "absolute
positioned floats", and "floating APs". There's no end to it but the
media (screens mostly) itself.
Oh, and of course, there will always be bugs...
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/