W3C home > Mailing lists > Public > public-html@w3.org > August 2008

Validating XHTML5 with XML entities

From: Jeff Schiller <codedread@gmail.com>
Date: Tue, 26 Aug 2008 16:36:12 -0500
Message-ID: <da131fde0808261436o56a9cbf1nc76a5b7fd0899058@mail.gmail.com>
To: "HTML WG" <public-html@w3.org>

The spec states that XHTML5 documents do not require a DOCTYPE [1].

A DOCTYPE must consist of "<!DOCTYPE HTML>" (case-insensitive) [2]

But a DOCTYPE is also where you declare XML entities.  For instance,
my blog software emits &nbsp; so I added an XML entity at the top of
my pages:

<!DOCTYPE html [
  <!ENTITY nbsp "&#160;">

Doing this seems to prohibit me from being able to generate valid
XHTML5 (at least the experimental portion of the W3C validator that
was recently added - html5.validator.nu does not complain).  Or maybe
XHTML5 is XML entites (among other things)?  Or maybe the DOCTYPE
definition could be expanded to optionally allow XML entities?

I'd appreciate some insight.  Yes, I can continue to hack on WordPress
and get it to emit "&#160;" instead of "&nbsp;" and then go through my
database and replace all instances for the last several years, but...

Jeff Schiller

[1] http://www.whatwg.org/specs/web-apps/current-work/multipage/infrastructure.html#editors
[2] http://www.whatwg.org/specs/web-apps/current-work/multipage/syntax.html#the-doctype
Received on Tuesday, 26 August 2008 21:36:53 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 29 October 2015 10:15:37 UTC