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 Rajan Gupta <ra...@rocketmail.com> on 2001/07/05 17:19:41 UTC

Xerces-J 1.4.1 problems with Schemas

For the following schema:
<?xml version="1.0"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:element name="gallery">
    <xsd:complexType>
     <xsd:sequence>
      <xsd:element name="image" maxOccurs="unbounded">
       <xsd:complexType>
        <xsd:attribute name="href" type="xsd:anyURI" use="required"/>
       </xsd:complexType>
      </xsd:element>
     </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>

For the following instance document:
<?xml version="1.0" encoding="UTF-8"?>
<gallery xmlns:xsi="http://www.w3.org/2000/10/XMLSchema-instance"
   xsi:noNamespaceSchemaLocation='personal.xsd'>
<image href="http://www.xfront.com/InSubway.gif"/>
</gallery>

The parser reports:
[Error] personal-schema.xml:3:49: Element type "gallery" must be
declared.
[Error] personal-schema.xml:4:51: Element type "image" must be
declared.

Why is this behaving like this 1.4.1

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org