[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Nested DTDs
BillGong <billinfo@s...> wrote: > I created 3 DTDs in XML Spy as below: > 1.report.dtd > <!ELEMENT report (title,paragraph+)> > <!ELEMENT title (#PCDATA)> > <!ELEMENT paragraph (#PCDATA|emph)*> > <!ELEMENT emph (#PCDATA)> > > 2.person.dtd > <!ELEMENT person (firstname, lastname)> > <!ELEMENT firstname (#PCDATA)> > <!ELEMENT lastname (#PCDATA)> > > 3.report_person.dtd > <!ENTITY % report "report.dtd"> > <!ENTITY % person "person.dtd"> > <!ELEMENT P_R (%person; , %report;)> > > When I create an XML file trying to use P_R in > report_person.dtd, it failed. Can anyone here tell > me the reason? Very thanks. > You need to use the SYSTEM keyword in your parameter entity declarations otherwise the parser treats them as literals. e.g. <!ENTITY % report SYSTEM "report.dtd"> Regards ~Rob -- Rob Lugt ElCel Technology http://www.elcel.com
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|