|
Posted by Randy Webb on 01/31/08 01:08
plenty900@yahoo.com said the following on 1/30/2008 7:51 PM:
> Hi folks,
>
> I've got some HTML like this:
>
> <DIV>
> <DIV style="float: left; width: 40"> text </DIV>
> <DIV style="float: left; width: 40"> text </DIV>
> <DIV style="float: left; width: 40"> text </DIV>
> </DIV>
> <DIV>
> <DIV style="float: left; width: 40"> text </DIV>
> <DIV style="float: left; width: 40"> text </DIV>
> <DIV style="float: left; width: 40"> text </DIV>
> </DIV>
>
> I'm finding that the second outer DIV is appearing
> to the right of the first outer DIV.
>
> My intention is to have the 2nd outer DIV
> appear below the first. I had assumed this
> would happen because its position is static
> by default.
>
> Can someone explain why it behaves
> the way it does?
I can. And I will if you explain what this has to do with Javascript.
float:left takes it out of the flow of the document. Your outer divs, in
this instance, are useless.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Navigation:
[Reply to this message]
|