G
Gustaf Liljegren
I ran into this example in the XML Schema Primer:
<internationalPrice currency="EUR" value="423.46"/>
The element is defined like this:
<xsd:element name="internationalPrice">
<xsd:complexType>
<xsd:complexContent>
<xsd:restriction base="xsd:anyType">
<xsd:attribute name="currency" type="xsd:string"/>
<xsd:attribute name="value" type="xsd:decimal"/>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
It looks complex indeed. I wonder what the difference is between the
above and this:
<xsd:element name="internationalPrice">
<xsd:complexType>
<xsd:attribute name="currency" type="xsd:string"/>
<xsd:attribute name="value" type="xsd:decimal"/>
</xsd:complexType>
</xsd:element>
Both works on the XML snippet, according to those WXS validators I've
tried.
Thanks,
Gustaf
<internationalPrice currency="EUR" value="423.46"/>
The element is defined like this:
<xsd:element name="internationalPrice">
<xsd:complexType>
<xsd:complexContent>
<xsd:restriction base="xsd:anyType">
<xsd:attribute name="currency" type="xsd:string"/>
<xsd:attribute name="value" type="xsd:decimal"/>
</xsd:restriction>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
It looks complex indeed. I wonder what the difference is between the
above and this:
<xsd:element name="internationalPrice">
<xsd:complexType>
<xsd:attribute name="currency" type="xsd:string"/>
<xsd:attribute name="value" type="xsd:decimal"/>
</xsd:complexType>
</xsd:element>
Both works on the XML snippet, according to those WXS validators I've
tried.
Thanks,
Gustaf