I think this quote from the HTML 5 Reference Draft provides the answer:
126.96.36.199 Void Elements
The term void elements is used to designate elements that must be empty. These requirements only apply to the HTML syntax. In XHTML, all such elements are treated as normal elements, but must be marked up as empty elements.
These elements are forbidden from containing any content at all. In HTML, these elements have a start tag only. The self-closing tag syntax may be used. The end tag must be omitted because the element is automatically closed by the parser.
A void element in the HTML syntax. This is not permitted in the XHTML syntax.
A void element using the HTML- and XHTML-compatible self-closing tag syntax.
A void element using the XHTML-only syntax with an explicit end tag. This is not permitted for void elements in the HTML syntax.
In other words:
- Invalid HTML:
- Valid HTML:
And while HTML forbids certain closing tags, xhtml requires them:
- Invalid xhtml:
- Valid xhtml:
Other elements that are forbidden from having a closing tag in HTML:
|Element ||Valid HTML ||Valid xhtml |
|AREA || |
|BASE || |
|BASEFONT || |
|BR || |
|COL || |
|FRAME || |
|HR || |
|IMG || |
|INPUT || |
|ISINDEX || |
|LINK || |
|META || |
|PARAM || |
The fact that HTML forbids certain closing tags, while xhtml requires them is xhtml's problem. If you're writing HTML, you follow the HTML rules.
At the same time, browers gave up trying to enforce the standards, because everyone gets it wrong. It's not obvious:
</BR> is forbidden
</P> is optional
</SPAN> is required
And then xhtml came along, with it's XML rule that every element must have a closing tag, and people just assumed that HTML was the same thing. So the standards gave up, and were later revised to throw up their hands to the reality.
<BR> is the only true form.