XML Schemas help you control what elements appear in your XML documents. Similar to Document Type Definitions, they offer distinct advantages over the older syntax. Dan Wellman provides a basic overview, with examples to get you started working on your own.
An Introduction to XML Schemas - The Complete File (Page 5 of 7 )
Anyway, as this is all that our extremely simple schema document needs in order to validate our extremely simple XML document, we can end the schema with the closing schema element:
Save the document with an .xsd prefix. As schema documents are just well-formed XML documents, you can also save it with an .xml prefix and load it up in a browser. If there are any typos or syntax errors in the schema, it won’t load. You need to use an XML compliant browser of course; for the purpose of this article, I’ve used MS IE6.