ZVON > Tutorials > XML Schema and Relax NG Tutorial |
Intro / Search / ZVON |
Index | >> Example 1 / 2 << | Prev | Next | |
If you want to add a human readable description of your schemas, use the element "documentation", which is a child of "annotation" element.
Valid document <root xsi:noNamespaceSchemaLocation="correct_0.xsd" xmlns="" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > test </root> |
Correct XML Schema (correct_0.xsd) <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" > <xsd:annotation> <xsd:documentation> My element "root", which contains only string. </xsd:documentation> </xsd:annotation> <xsd:element name="root" type="xsd:string"/> </xsd:schema> |
Relax NG allows you to place arbitrary elements from other namespaces into your schema.
Valid document <root xmlns=""> test </root> |
Correct Relax NG schema (correctRelax_0.rng) |