> -----Original Message----- > From: Philippe Wittenbergh [mailto:[EMAIL PROTECTED] > Sent: Wednesday, August 30, 2006 9:41 PM > To: CSS-D > Subject: Re: [css-d] div blocks in forms don't clear in Firefox 1.5.x > > > On Aug 31, 2006, at 8:30 AM, Burleigh, Frank wrote: > > > P's inside of formrow's float left, then we start a new row > by closing > > the div and following with a new one. So the markup is a little > > laborious but it does give nice control for style hints. > > > > I've recently found that the divs in this markup/styling don't serve > > their clearing (block) fundtion in Firefox 1.5.4 and 1.5.6 at > > least, but > > are ok in 1.0.7 and 2.x. I've extracted css and html into s reduced > > case. > > > > http://toaster.law.indiana.edu/exhibits/layout/form_block.html > > > > I've also tried putting style on the divs to insist that they > > clear--even that doesn't help, so it doesn't seem like a specificity > > issue. > > > > <https://bugzilla.mozilla.org/show_bug.cgi?id=309550> > > based on your test file: > div.formrow { > clear:both; > display:table; > } > You can also use overflow:hidden instead of display:table > > Essentially, use one of the properties that establish a new block > formatting context. > This results in the a block that contains the floated elements. > > <http://dev.l-c-n.com/IEW/simulations.php> > <http://www.w3.org/TR/CSS21/visuren.html#block-formatting> > > > Philippe > --- > Philippe Wittenbergh > <http://emps.l-c-n.com> Thanks very much, Philippe. The rule "clear:both" had not cleared the floats, but your suggested rule "display:table" does. But that hack introduced a new problem: select inputs inside floated p elements seemed to create their own formatting block, breaking the flow of inputs. Using your alternative rule "overflow:hidden" works around not only the too-little clearing problem but also the too-aggressive clearing side effect. I don't see other side effects in Firefox 1.5.x or 2.x or IE 6.x.
Frank Burleigh Indiana University School of Law [EMAIL PROTECTED] 812-855-9170 ______________________________________________________________________ css-discuss [EMAIL PROTECTED] http://www.css-discuss.org/mailman/listinfo/css-d IE7b2 testing hub -- http://css-discuss.incutio.com/?page=IE7 List wiki/FAQ -- http://css-discuss.incutio.com/ Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
