Re: XML declaration

> Date: Thu, 4 Mar 1999 20:01:02 -0700
> From: Susan Lesch <lesch@macvirus.com>
> Subject: XML declaration
> 
> Does XHTML require an XML declaration?

No, at least according to the XML recommendation.  However, it is
useful for character encoding information.  This is because the XML
spec says a document is [2]:

  document ::=  prolog element Misc* 

where prolog is [3]:

  prolog ::=  XMLDecl? Misc* (doctypedecl Misc*)? 

and XMLDecl is the XML declaration and Misc is comments, whitespace, or
processing instructions.
 
> Because MSIE Mac downloads rather than displays documents with an XML
> declaration (corrections welcome), the answer to this question might mean
> the difference between using and not using XHTML.

Great.  What fun...

On another note... the ".dtd" wasn't taken out of the xmlns in the
example in section 3.1. [4]  Furthermore, the contents at the top
number the subsections using letters, but the text gives them numbers.

David Baron

> [1] http://www.w3.org/TR/WD-html-in-xml/

[2] http://www.w3.org/TR/REC-xml#sec-well-formed
[3] http://www.w3.org/TR/REC-xml#NT-prolog
[4] http://www.w3.org/TR/WD-html-in-xml/#docconf

Received on Thursday, 4 March 1999 23:47:28 UTC