W3C home > Mailing lists > Public > www-html@w3.org > April 2000

RE: Ignoring empty paragraphs

From: <JOrendorff@ixl.com>
Date: Mon, 10 Apr 2000 18:14:48 -0400
Message-ID: <CD8E2CDBC6D0D111ACB900805FBBD97E0263029B@host131sub18.offices.ixl.com>
To: www-html@w3.org
I wrote:
>> <div>foo</div><p></p><div>bar</div>
>> The <p> is not "ignored" here;
>> it introduces a gap of about 1em, depending on your browser's
>> setting for margins on <p>.

Jan Roland Eriksson replied:
> It does _not_ in Mozilla M14 "strict" mode.
> (yes, I did try exactly your line up here before posting :)

If it doesn't, then perhaps it is pruning the empty <p> elements
altogether, before the rendering engine sees them.  In any case,
CSS2 requires the gap if the <p> elements remain in the tree:

CSS2 Recommendation, Section 8.3.1, "Collapsing Margins":
] Two or more adjoining vertical margins of block boxes in the
] normal flow collapse. The resulting margin width is the maximum
] of the adjoining margin widths.

Jason Orendorff
Received on Monday, 10 April 2000 18:23:53 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:05:53 UTC