Re: Validator Bugreport

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

Categories:
	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:

<p></p><div></div></p>

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

-- 
David Dorward
http://dorward.me.uk

Received on Monday, 16 July 2012 13:26:40 UTC