W3C home > Mailing lists > Public > public-qt-comments@w3.org > April 2004

Re: FW: XSLT 2.0: XML Output Method: the omit-xml-declaration Parameter

From: Henry Zongaro <zongaro@ca.ibm.com>
Date: Tue, 13 Apr 2004 10:51:18 -0400
To: "Deborah Cawkwell" <deborah.cawkwell@bbc.co.uk>
Cc: public-qt-comments@w3.org
Message-ID: <OF55A7725D.863E3E99-ON85256E74.006F96C0-85256E75.00519852@ca.ibm.com>


     In [1], you submitted the following comment on the Last Call Working 
Draft of XSLT 2.0 and XQuery 1.0 Serialization.

> 4.5 XML Output Method: the omit-xml-declaration Parameter 
> http://www.w3.org/TR/2003/WD-xslt-xquery-serialization-20031112/#N105F3 
> This says: "The omit-xml-declaration parameter must be ignored if the 
> standalone parameter is present, or if the encoding parameter specifies 
> a value other than UTF-8 or UTF-16." 
> I would like to control the output of the omit-xml-declaration 
> parameter, where the encoding parameter specifies a value other than
> UTF-8 or UTF-16. I often don't use Unicode. I would like the option 
> to output with non-standard encoding as XHTML. The XHTML standard (
> http://www.w3.org/TR/xhtml1/) specifies that "an XML declaration is 
> not required in all XML documents"; it is often desirable to omit 
> it, given that it is known that there are unexpected results with 
> some user agents.

     Thank you for your comment.

     The XSL and XQuery Working groups discussed your comment.  As 
originally written, XML 1.0 required an XML declaration or a text 
declaration if the encoding of the document or external general parsed 
entity was anything other than UTF-8 or UTF-16.  XSLT 1.0 enforced that 
requirement in its serialization mechanism.  The draft of Serialization 
inherited that behaviour from XSLT 1.0.  However, an erratum to XML 1.0 
removed that requirement.

     In response to your comment, the working groups decided to require 
the XML declaration or text declaration to be omitted, regardless of the 
setting of the encoding parameter.  Serialization will permit an XML 
declaration or text declaration to be omitted in precisely those 
circumstances in which it can be omitted according to XML 1.0 and XML 1.1. 
 This would affect both the xml and xhtml output methods.

     As that is the change you requested, I believe that decision will be 
acceptable to you.   May I ask you to confirm that it is?


Henry [On behalf of the XSL and XQuery Working Groups.]
Henry Zongaro      Xalan development
IBM SWS Toronto Lab   T/L 969-6044;  Phone +1 905 413-6044
Received on Tuesday, 13 April 2004 10:52:08 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:56:56 UTC