Friends
My Xml is not getting correctly validated against the XSD.
I expect the browser to through atleast some kind of generic error messages.But it is not happening.I have installed MSXML4 in my PC
My Xml file is below
note.Xml
I purposefully removed the <to> tag from the above xml to see some errors.
My Xsd file is below
note.xsd
Both the note.xml and note.xsd files are in the same folder.
Can somebody guide why i am not getting any error?
My Xml is not getting correctly validated against the XSD.
I expect the browser to through atleast some kind of generic error messages.But it is not happening.I have installed MSXML4 in my PC
My Xml file is below
note.Xml
Code:
<?xml version="1.0"?> <note xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:SchemaLocation="note.xsd"> <from>Jani</from> <heading>Reminder</heading> <body>Don't forget me this weekend!</body> </note>
My Xsd file is below
note.xsd
Code:
<?xml version="1.0"?> <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.w3schools.com" xmlns="http://www.w3schools.com" elementFormDefault="qualified"><xs:element name="note"> <xs:complexType> <xs:sequence> <xs:element name="to" type="xs:string" /> <xs:element name="from" type="xs:string"/> <xs:element name="heading" type="xs:string"/> <xs:element name="body" type="xs:string"/> </xs:sequence> <xs:attribute name="to" type="xs:string" use="required"/> </xs:complexType> </xs:element></xs:schema>
Can somebody guide why i am not getting any error?
Comment