Hi,
I have a simple XSD for example like this:
<?xml version="1.0"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified" attributeFormDefault="qualified">
<xs:element name="customer">
<xs:complexType mixed="false">
<xs:sequence>
<xs:element name="name" type="xs:string"/>
<xs:element name="age" type="xs:int"/>
</xs:sequence>
<xs:anyAttribute namespace="##any"/>
</xs:complexType>
</xs:element>
</xs:schema>
I also have a simple template attribute language engine to process an XHTML
document and in one of the attribute I have a directive for example
"/customer/age" (derived from the XPath here). When the engine see this
directive it needs to replace the content of that tag with the apropriate
HTML fragment. To find the correct HTML fragment i need to find out the type
based on the XSD. In this example it will be xs:int.
The question is how do I get the type from my XSD given the "/customer/age"
information? Is this possible to do so? Anyone has any hint for this?
Thanks