[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- From: David Megginson <email@example.com>
- To: firstname.lastname@example.org
- Date: Thu, 01 Mar 2001 17:45:29 -0500
Tim Bray writes:
> Of course the great risk in this kind of thinking is that you
> start to believe that in general you have to apply a schema
> before you can start to do useful work with a chunk of XML.
If the schema (DTD, XML Schema, or what-have-you) contains default
information of any sort, such as attribute values or even character
data, and the document instance relies on those defaults, then either
(a) you have to hand-code the defaults in your own processing code, or
(b) you have to require all receivers to read the schema.
(a) is the more practical approach, though you run the risk of letting
your code fall out of sync with the schema; (b) is full of security
and performance holes.
My preference is to include all defaulted information in production
instances and not to include a DOCTYPE declaration or schema link at
all -- that's the only way to ensure that all clients see the same
document, and that no one does anything stupid.
All the best,
David Megginson email@example.com
- re: PSVI
- From: "Simon St.Laurent" <firstname.lastname@example.org>
- re: PSVI
- From: Sean McGrath <email@example.com>
- Re: more grist
- From: Ben Trafford <firstname.lastname@example.org>
- From: Tim Bray <email@example.com>