|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] re: PSVI
At 05:45 PM 3/1/01 -0500, David Megginson wrote: >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. Generally speaking, I think David's right, though there are at least two options which permit the use of DTD defaulting without the security risks, inflexibility, or other potential hassles. a) rely on PUBLIC identifiers mapped to a local cache. Treat the system identifier as merely a convenience for the sender, but require PUBLIC identifiers which match to a list of DTDs maintained by the program. See http://xmlhack.com/read.php?item=392 for information and Arbortext's implementation. b) modify the DOCTYPE declaration of incoming documents to reflect a type your program expects, and point it at a local resource. I've written a DOCTYPEChanger filter in Java which does this - http://simonstl.com/projects/doctypes/. It's not that difficult. Both of these allow you to use DTD-based defaulting without relying on external DTD resources and the kindness of senders. Neither one is widely used in practice, from what I've heard from people, but they can be helpful at times. (And instead of Infoset vs. PSVI, I'd love people to start thinking in terms of SI - standalone [no external resource] infoset, DTDI - DTD-influenced infoset, and then PSVI. Brought to you by the Committee for Unusable Acronyms, CUA.) Simon St.Laurent - Associate Editor, O'Reilly and Associates XML Elements of Style / XML: A Primer, 2nd Ed. XHTML: Migrating Toward XML http://www.simonstl.com - XML essays and books
|
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
|
|||||||||

Cart








