posted 13 years ago
Hi,
I can able to write DTD and XML in one file. Please find the below example.
<?xml version="1.0"?>
<!DOCTYPE note [
><!ELEMENT note (to,from,heading,body)>
<!ELEMENT to (#PCDATA)>
<!ELEMENT from (#PCDATA)>
<!ELEMENT heading (#PCDATA)>
<!ELEMENT body (#PCDATA)>
]>
<note>
<to>Tove</to>
<from>Jani</from>
<heading>Reminder</heading>
<body>Don't forget me this weekend</body>
</note>
Now my doubt is can we write Schema and XML also in the same fashion without referring xsd file at the top.
If Yes can any one provide one example.
Thanks in Advance
Subbarao Kondabala
Thanks and Regards,
Subbarao Kondabala