This tip shows you how to import an XML schema in your XSL pages, using XSLT 2.0. For example, if your XML schema is named schema.xsd and it is stored in the same directory with your stylesheet, then you can import it like this:
If you want, you can define “rules” directly into the stylesheets by using the xs:schema element. In this case, you must skip the schema-location attribute. For example: