[
Lists Home |
Date Index |
Thread Index
]
Julian Reschke wrote:
>> [using URLs to reference DTD's causes all sorts of problems]
> Yes. Don't do that. Either do not validate at all, or validate against a
> local copy. This is common sense. I'm surprised how frequently people make
> this mistake.
>
Quite correct. I usually delete DTD references from static XML
files before I deploy them into the production environment. There
is no benefit in validating a read-only document every time it is
read.
Even if referencing a DTD can't be avoided, all environments I
worked in have more or less well developed catalog mechanisms for
mapping DTD references to local copies. Even BEA claims to have
one.
Validation should be thought of a tool useful while manually
manipulating XML documents, during development and for checking
XML documents you get from sources you don't quite trust. In
order to promote this point of view, it would help if
validation was not as tightly integrated into XML parsing as it
currently is (because DTDs define both physical and logical
structure of the XML document), but rather seen as a separate
step which *could* be integrated into the parser for pure
efficiency reasons.
J.Pietschmann
|