Sundial Services wrote: > > As for the future... putting (say) "<!DOCTYPE>" declarations into a > few hundred files is short-work for a Perl script. (But will this > confuse things if the file starts with "<refentry>?" Only one way to > find out, I guess...) >
There are two ways to write clean, ``portable'', modular documents: [A] Use references to external entities and in such case, an included file must *not* start with <!DOCTYPE>. If this is not the case, the XML parser will reject your master document as non-well-formed. [B] OR Use XIncludes and in such case, the included file (e.g. a refentry) must really start with the proper <!DOCTYPE> (e.g. <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">) If this is not the case, XML processors such as Xerces or xmllint will fail to process any XInclude making use of an element ID (e.g. <xi:include href="my_function.xml" xpointer="examples"/>) Therefore, now that we know that you use XIncludes, we really recommend that you write and run this Perl script in order to add the proper <!DOCTYPE> to your numerous XML files.

