Hi all, I'm currently scratching my head over the following problem. I have a validating parser for which the reference schema is specified through code ( setAttribute(JAXP_SCHEMA_SOURCE, schema); ). The reference schema has a target namespace. The parser works fine, but surprisingly completely fails to detect an file which has both a different namespace and a reference to its own schema.
To sum up, given the following schema : <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="official/namespace" ... and the following code : setAttribute(JAXP_SCHEMA_SOURCE, "path/to/official/schema") Then a document like this : <foo xmlns="different/namespace" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="different/namespace path/to/different/schema.xsd"> will be seen as valid by the parser. Is there a way to get the parser to reject the document, without resorting to manuall checking the document's namespace ? Thanks, -- Guillaume Laurent OASIS, Inria Sophia-Antipolis http://www-sop.inria.fr/oasis/ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]