[Home] [By Thread] [By Date] [Recent Entries]

  • To: <xml-dev@l...>
  • Subject: DOCTYPE declaration in the document prolog
  • From: "P. Karki" <karki@p...>
  • Date: Tue, 24 Sep 2002 17:57:30 +0900
  • Disposition-notification-to: "P. Karki" <karki@p...>
  • Reply-to: "P. Karki" <karki@d...>

Is following XML sample valid?
Please note that the internal declaration subset does not
declare the "test" element. IE normally opens this sample.
My understanding was that the root element should
also be declared in the internal declaration subset
if there is no external declaration subset.
Am I misunderstood? 
Where can I find clear information about this?

<?xml version="1.0"?>
<!DOCTYPE test
[
<!ELEMENT data (year, kcode, bcode)>
<!ELEMENT year (#PCDATA)>
<!ELEMENT kcode (#PCDATA)>
<!ELEMENT bcode (#PCDATA)>
]>
<test>
<data>
<year>2002</year>
<kcode>001</kcode>
<bcode>002</bcode>
</data>
</test>

--
P. Karki
Daitec Co., Ltd.
Hiroshima

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member