Huma 0 Posted March 16, 2006 Report Share Posted March 16, 2006 DEAR ALL,I WANT TO USE FOLLOWING SCHEMA FILE <?xml version="1.0" encoding="UTF-8" ?><xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.example.com" xmlns="http://www.example.com"> <!-- global element declaration validates <language> elements from http://www.example.com namespace --> <xs:element name="language" type="xs:string" /> <xs:element name="Root" type="sequenceOfLanguages" /> <xs:element name="Root2" type="sequenceOfLanguages2" /> <!-- complex type with local element declaration validates <language> elements without a namespace name --> <xs:complexType name="sequenceOfLanguages" > <xs:sequence> <xs:element name="language" type="xs:NMTOKEN" maxOccurs="unbounded" /> </xs:sequence> </xs:complexType> <!-- complex type with reference to global element declaration --> <xs:complexType name="sequenceOfLanguages2" > <xs:sequence> <xs:element ref="language" maxOccurs="10" /> </xs:sequence> </xs:complexType></xs:schema>WITH THIS XML FILE.<?xml version="1.0"?><ex:Root xmlns:ex="http://www.example.com"> <language>EN</language> </ex:Root> BUT IT IS NOT WORKING.I AM NOT GETTING THE CONCEPT OF LOCAL AND GLOBAL ELEMENTS IN SCHEMA.CAN ANYBODY HELP ME?BEST REGARDSHUMA Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.