The validator skipped the p tag, but it is there!
I have the following markup:
<footer> <p id="foo"> ©Copyright. <address><a href="" title="Web Development">Me</a></address>. Todos os direitos reservados. </p> </footer> But the W3 Validator (HTML 5) says:
Error Line 81, Column 20: No p element in scope but ap end tag seen. </p> I have a tag p. What's wrong? Thanks.
Problem:
<p>cannot contain<address>block
You can insert <p> inside <address> ! The <address> block simply means that address information will be found in it. It does not need to be wrapped tightly around the address itself.
http://www.whatwg.org/specs/web-apps/current-work/multipage/sections.html#the-address-element
Layout problem:
why use a shell like 'p or' div to encode the layout? as an element of the block level, you can use the "address" directly as a container container and format it with any css as you wish. keep the code minimal and simple.
Semantic problem:
also, you donβt need the 'p wrapper for semantics, since the' address explains its contents very well. just use it; -)
Syntax issue:
and yes, the other answers are correct: 'p contains legally only inline / inline block elements, not allowed block level elements