[whatwg] Paragraphs in blockquotes

Ian Hickson ian at hixie.ch
Tue Aug 3 16:15:55 PDT 2010


On Tue, 11 May 2010, Richard Clark wrote:
> 
> We recently received an email from one of our readers on html5doctor.com 
> that went like this:
> 
> "Hi, in HTML 4.0 Strict & XHTML 1.0 Strict, text inside a blockquote 
> element is required to be nested inside another block-level element, 
> e.g. p. In HTML5 that requirement seems to have been relaxed, as the 
> following element validates successfully:
> 
> <blockquote>This is a blockquote.</blockquote>
> 
> The HTML5 spec uses the p element in the usage examples, but does not 
> mention whether it is required.
> 
> Can you please confirm if this requirement has now been deprecated?"
> 
> We tested the below which successfully validated:
> 
> <!doctype html>
> <meta charset=utf-8>
> <title>blockquote test</title>
> <blockquote>Tiger tiger burning bright</blockquote>
> 
> So the question is, are block level elements required in blockquotes or 
> can the p's be removed from the examples in the spec?

On Tue, 11 May 2010, Masataka Yakura wrote:
> 
> <blockquote> can take any flow content [...]
> 
> So in HTML5 <blockquote> doesn't require inline contents to be nested 
> inside another block elements (you may know but that was acceptable too 
> in HTML4 Transitional).

On Tue, 11 May 2010, Futomi Hatano wrote:
> 
> The content model for <blockquote> is Flow content.
> Flow content includes "text".
> So, the text as a child of <blockquote> is valid.
> 
> The spec says that a run of phrasing content (in this case, it is the 
> text.) is a paragraph. 
> http://www.whatwg.org/specs/web-apps/current-work/multipage/content-models.html#paragraph 
> So, the examples below have same semantics.
> 
> <blockquote>This is a blockquote.</blockquote>
> <blockquote><p>This is a blockquote.</p></blockquote>
> 
> The former is valid, but, of course, authers are encouraged the latter 
> much more.

Indeed.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'



More information about the whatwg mailing list