You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by "Nestel, Frank" <fr...@coi.de> on 2001/06/15 11:35:02 UTC
Schema Location Strategy
Hi,
I just realized I do not understand the Schema location strategy
used by Xalan 1.4.0:
I have a document which contains elements located in two namespaces:
"" and "http://www.spieleck.de/fdpd" with a start like
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE f:fdpd [
<!ENTITY nbsp " ">
<!ENTITY copy "©">
<!ENTITY auml "ä"> <!-- LATIN SMALL LETTER A WITH DIAERESIS
-->
<!ENTITY Auml "Ä"> <!-- LATIN CAPITAL LETTER A WITH
DIAERESIS -->
<!ENTITY ouml "ö"> <!-- LATIN SMALL LETTER O WITH DIAERESIS
-->
<!ENTITY Ouml "Ö"> <!-- LATIN CAPITAL LETTER O WITH
DIAERESIS -->
<!ENTITY szlig "ß"> <!-- LATIN SMALL LETTER SHARP S -->
<!ENTITY uuml "ü"> <!-- LATIN SMALL LETTER U WITH DIAERESIS
-->
<!ENTITY Uuml "Ü"> <!-- LATIN CAPITAL LETTER U WITH
DIAERESIS -->
]>
<f:fdpd version="1.0"
xmlns:f="http://www.spieleck.de/fdpd"
xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:schemaLocation='http://www.spieleck.de/fdpd fdpd.xsd'
>
The document shall be validated against a schema located in the same local
filesystem in a file named "fdpd.xsd"
Now, if I augment the initial element to
<f:fdpd version="1.0"
xmlns:f="http://www.spieleck.de/fdpd"
xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:schemaLocation='http://www.spieleck.de/fdpd fdpd.xsd'
>
Now using an validating instance of Xerces I get the error
http://www.spieleck.de/fdpd grammar not found
Same happens if I use
<f:fdpd version="1.0"
xmlns:f="http://www.spieleck.de/fdpd"
xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:noNamespaceSchemaLocation='fdpd.xsd'
>
If I change first element to
<f:fdpd version="1.0"
xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xsi:schemaLocation='http://www.spieleck.de/fdpd fdpd.xsd'
>
I get no message about missing grammar file, but of course I havent
declared my namespace and all is wrong. Especially I do not think Xerces
is reading the fdpd.xsd file since when I render it syntactical wrong,
I do not get any error message about the schema.
I am very confused right now :-(
Thank you,
Frank
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org