You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by George Tsai <GT...@scient.com> on 2000/06/15 03:16:19 UTC
Does Xerces 1.1.1 support PUBLIC identifiers
Hi,
I am using xerces 1.1.1 to process some XML documents with PUBLIC
identifiers.
<!DOCTYPE DOC PUBLIC "-//MyDOC//MyDOC Rev2 Body Content V1.0//EN" [
<!ENTITY % revision "MyDOC Rev 2">
]>
Xerces throws an exception:
"The system identifier must begin with either a single or double quote
character."
The XML authoring tools requires the PUBLIC identifier and is resolved
through a catalog file. I can change the PUBLIC identifier to a SYSTEM
identifier, but it will be less portable given different configurations for
different XML writers.
Any solutions? Thanks.
George
Re: Does Xerces 1.1.1 support PUBLIC identifiers
Posted by Andy Clark <an...@apache.org>.
George Tsai wrote:
> I am using xerces 1.1.1 to process some XML documents with PUBLIC
> identifiers.
>
> <!DOCTYPE DOC PUBLIC "-//MyDOC//MyDOC Rev2 Body Content V1.0//EN" [
> <!ENTITY % revision "MyDOC Rev 2">
> ]>
>
> Xerces throws an exception:
> "The system identifier must begin with either a single or double quote
> character."
If you look at the productions in the XML specification, you'll
notice that even though you specify a PublicId, you also have
to specify a SystemId. Since your document starts the internal
subset immediately after the PublicId, this is an error.
Look at productions [28] and [75] in the XML specification for
details.
--
Andy Clark * IBM, JTC - Silicon Valley * andyc@apache.org