XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Re: [xml-dev] [Summary] Why is Encoding Metadata (e.g. encoding="UTF-8")put Inside the XML Document?

Costello, Roger L. wrote:
> Very interesting!
> 
> Here's the description I now have:
> 
> Assuming external information did not decide the encoding ...
> 
> An XML Parser will make an initial "guess" of the encoding based upon
> the presence or absence of a Byte Order Mark (BOM). The XML parser then
> interprets the bit strings using that guess up to the first ">"
> character (the end of the XML declaration).  Now that it knows the
> "real" encoding it interprets the rest of the document using the
> encoding it found in the XML declaration.
> 
> Do I have it correct?

	'<?xml' VersionInfo  EncodingDecl? SDDecl? S? '?>'

So the encoding is optional?

Need to cater for the great unwashed too!


regards



-- 
Dave Pawson
XSLT, XSL-FO and Docbook FAQ
http://www.dpawson.co.uk



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS