kwokwai
04-25-2007, 02:25 PM
Hi, I am learning XML and DTD.
To start with my first lesson, I wrote a test.xml and a test.dtd files which contents are as follows:
test.xml:
<?xml version="1.0"?>
<!DOCTYPE address SYSTEM "test.dtd">
<address>
<street> 170 Lygon St.</street>
<city>Melbourne</city>
<state>Victoria</state>
<zip>3000</zip>
<country>A</country>
</address>
test.dtd:
<?xml version="1.0"?>
<!DOCTYPE address [
<!ELEMENT address (street+, city, state, zip, country?)>
<!ELEMENT street (#PCDATA)>
<!ELEMENT city (#PCDATA)>
<!ELEMENT state (#PCDATA)>
<!ELEMENT zip (#PCDATA)>
<!ELEMENT country (#PCDATA)>
]>
But then when I loaded the page in my I.E.6, I got this error message:
multiple DOCTYPE declarations....
Any ideas how solve the problem?
To start with my first lesson, I wrote a test.xml and a test.dtd files which contents are as follows:
test.xml:
<?xml version="1.0"?>
<!DOCTYPE address SYSTEM "test.dtd">
<address>
<street> 170 Lygon St.</street>
<city>Melbourne</city>
<state>Victoria</state>
<zip>3000</zip>
<country>A</country>
</address>
test.dtd:
<?xml version="1.0"?>
<!DOCTYPE address [
<!ELEMENT address (street+, city, state, zip, country?)>
<!ELEMENT street (#PCDATA)>
<!ELEMENT city (#PCDATA)>
<!ELEMENT state (#PCDATA)>
<!ELEMENT zip (#PCDATA)>
<!ELEMENT country (#PCDATA)>
]>
But then when I loaded the page in my I.E.6, I got this error message:
multiple DOCTYPE declarations....
Any ideas how solve the problem?