Wenn du schönen Code schreiben willst, solltest du wenigstens noch drauf hinweisen, dass das nur für XHTML gilt. Der W3C Validator wirft zwar für ein <br /> in HTML 4.01 Strict keinen Fehler aber eine Warnung:
Warum sie da also ne Warnung statt nem Fehler schmeißen ist mir rätselhaft, da nach Standard das in HTML 4.01 Strict eigentlich implizit zu <br> /> werden müsste, was zumindest wegen des > statt > einen Error werfen sollte. :DZitat:
NET-enabling start-tag requires SHORTTAG YES.
<p>foo<br />bar</p>
The sequence <FOO /> can be interpreted in at least two different ways, depending on the DOCTYPE of the document. For HTML 4.01 Strict, the '/' terminates the tag <FOO (with an implied '>'). However, since many browsers don't interpret it this way, even in the presence of an HTML 4.01 Strict DOCTYPE, it is best to avoid it completely in pure HTML documents and reserve its use solely for those written in XHTML.