W3C home > Mailing lists > Public > www-validator@w3.org > July 2012

Re: Validator Bugreport

From: David Dorward <david@dorward.me.uk>
Date: Mon, 16 Jul 2012 14:26:03 +0100
Cc: <www-validator@w3.org>
Message-Id: <DA5868AC-B90A-4D63-BEEC-ED5A52162B4D@dorward.me.uk>
To: webmaster@x-odus.com

On 16 Jul 2012, at 11:51, webmaster@x-odus.com wrote:
>         <p>
>             <div>
>             </div>
>         </p>
> The validator returns an error:
> Line 11, Column 12: No p element in scope but a p end tag seen.
> IMHO this is incorrect.

4.5.1 The p element

	Flow content.
	Palpable content.
Contexts in which this element can be used:
	Where flow content is expected.
Content model:
	Phrasing content.

A div element is not Phrasing content, so the div start tag terminates the p element implicitly.

Thus your markup is parsed as:


There is no start tag that matches the explicit end tag for the p element.

David Dorward
Received on Monday, 16 July 2012 13:26:40 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 16 July 2012 13:26:46 GMT