I
Ingrid
I am trying to create a schema with my own namespace/prefix "in:"
instead of xs: (to be able to import it into a different schema
afterwards) - but can't seem to make it work.
Trying to validate the schema below, the parser keeps on finding an
error at line <in:extension base="pageRange">
The same schema validates ok when the conventional xs: namespace is
used.
Any ideas?
Ingrid
<in:schema targetNamespace="http://did/in"
elementFormDefault="qualified"
attributeFormDefault="unqualified"
xmlns:in="http://www.w3.org/2001/XMLSchema" >
<in:element name="num" type="numType"></in:element>
<in:complexType name="numType">
<in:simpleContent>
<!-- ERROR ---- ???>
<in:extension base="pageRange">
<!-- ERROR ---- ????>
<in:attribute name="type" use="required">
<in:simpleType>
<in:restriction base="in:string">
<in:enumeration value="page
range"></in:enumeration>
</in:restriction>
</in:simpleType>
</in:attribute>
</in:extension>
</in:simpleContent>
</in:complexType>
<in:simpleType name="pageRange">
<in:restriction base="in:string">
<in:minLength value="3"></in:minLength>
<in:maxLength value="7"></in:maxLength>
<inattern value="\d{1,3}-\d{1,3}"></inattern>
</in:restriction>
</in:simpleType>
</in:schema>
instead of xs: (to be able to import it into a different schema
afterwards) - but can't seem to make it work.
Trying to validate the schema below, the parser keeps on finding an
error at line <in:extension base="pageRange">
The same schema validates ok when the conventional xs: namespace is
used.
Any ideas?
Ingrid
<in:schema targetNamespace="http://did/in"
elementFormDefault="qualified"
attributeFormDefault="unqualified"
xmlns:in="http://www.w3.org/2001/XMLSchema" >
<in:element name="num" type="numType"></in:element>
<in:complexType name="numType">
<in:simpleContent>
<!-- ERROR ---- ???>
<in:extension base="pageRange">
<!-- ERROR ---- ????>
<in:attribute name="type" use="required">
<in:simpleType>
<in:restriction base="in:string">
<in:enumeration value="page
range"></in:enumeration>
</in:restriction>
</in:simpleType>
</in:attribute>
</in:extension>
</in:simpleContent>
</in:complexType>
<in:simpleType name="pageRange">
<in:restriction base="in:string">
<in:minLength value="3"></in:minLength>
<in:maxLength value="7"></in:maxLength>
<inattern value="\d{1,3}-\d{1,3}"></inattern>
</in:restriction>
</in:simpleType>
</in:schema>