W3C home > Mailing lists > Public > www-validator@w3.org > February 2010

Re: Self closing <div> is valid, but shouldn't be

From: David Dorward <david@dorward.me.uk>
Date: Mon, 1 Feb 2010 07:55:32 +0000
Cc: <www-validator@w3.org>
Message-Id: <9EC00467-3DB4-4EF3-931F-D5520C79DB4F@dorward.me.uk>
To: "Briere, William J" <wjbriere@seattleschools.org>

On 29 Jan 2010, at 00:02, Briere, William J wrote:

> If you enter html via direct input it states that a self closing div is valid, but it shouldn’t be.
I've just tested it. It reports it as invalid.

In XHTML, it reports it as valid, but that is correct (it isn't HTML compatible, but that isn't a matter of validity).

> Check out the w3c reference here.http://www.w3schools.com/tags/ref_byfunc.asp
Note that W3Schools is not affiliated with the W3C ... and is generally of low quality.

However I can not see any claim on that page that self-closing tag syntax is forbidden for div elements.

David Dorward
Received on Monday, 1 February 2010 07:57:00 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 March 2016 14:18:00 UTC