W3C home > Mailing lists > Public > public-html-xml@w3.org > January 2011

Re: HTML5 output method

From: Michael Kay <mike@saxonica.com>
Date: Mon, 03 Jan 2011 19:26:14 +0000
Message-ID: <4D2222D6.2000001@saxonica.com>
To: John Cowan <cowan@mercury.ccil.org>
CC: Henri Sivonen <hsivonen@iki.fi>, public-html-xml@w3.org

> XML serializers, including those used by XSLT, are free to use xmlns
> attributes exclusively and never generate a prefix.

That's not correct. The XSLT 2.0 / XQuery 1.0 serialization 
specification is prescriptive about what prefix should be used. This is 
for two reasons:

(a) DTDs such as the XHTML DTD that make a document invalid if the wrong 
prefix is used

(b) Some vocabularies use QNames (or XPath expressions) in element or 
attribute content (xsi:type="xs:integer"), and these rely on the correct 
prefix being declared.

Moreover, you can't "use xmlns attributes exclusively and never generate 
a prefix" if there are namespaced attributes such as xlink:href.

None of this, of course, stops us defining an HTML5 serialization 
method. Doing so requires many detailed questions to be resolved, but 
they are tactical questions, and I'm not sure it's productive for this 
TF to address them - we should be more concerned with strategy/policy.

One of the policy questions is whether every XDM instance should have an 
HTML5 serialization (and if so, whether that serialization should always 
be prescriptively defined in the specification), or whether some 
instances should result in serialization errors.
>>   * Output escaping needs to be turned off for text content in these
>>   elements in the http://www.w3.org/1999/xhtml namespace: "iframe",
>>   "noembed", "noframes", "noscript", "plaintext", "script", "style",
>>   "xmp"
> In XSLT, output-escaping is suppressed by the generative mechanism,
> not by the output mode.
Not so: for example the XSLT 2.0 HTML output method says "The HTML 
output method MUST NOT perform escaping for the content of the script 
and style elements."

Michael Kay
Received on Monday, 3 January 2011 19:26:44 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 19:58:27 UTC