Subject: how XSL processor treat doctype declaration in source From: "Carole E. Mah" <carole@xxxxxxxxxxxxxxxxxx> Date: Thu, 30 Mar 2000 11:31:08 -0500 (EST) |
I'm still confused about how XSL processors react to or treat the doctype declaration in the source file. Elliot Rusty Harold's tutorial on XSLT (XML Bible Chapter 14) says: "XSL processors assume an XML tree contains seven kinds of nodes. These are: The root Elements Text Attributes Namespaces Processing instructions Comments The DTD and document type declaration are specifically not included in this tree. If present, they're ignored, with the single exception that they may add additional attribute nodes to some elements that are declared to have default attributes." "If present, they're ignored..." for the most part. If this is so, then why is it that I get weird results if I include the doctype declaration in my source file? e.g. sometimes when the dtd line is in the source file, no processing occurs, and only <?xml ... ?> is output; other times processing occurs but only CDATA/text is output and all templates seem to be ignored (because the default for text nodes is to output them unchanged); other times processing occurs but weird things happen (as happened to my colleague recently) such as the doctype getting output with no STAGC: <!doctype ... instead of <!doctype ...> Thanks, -carole - - - - - - - - - - - - - - - - - - - - - - - - - Carole E. Mah Carole_Mah@xxxxxxxxx Senior Programmer/Analyst Brown University Scholarly Technology Group phn 401-863-2669 fax 401-863-9313 http://www.stg.brown.edu/ personal: http://www.stg.brown.edu/~carolem/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: Re: expandble list in XSL, Johan Andreasson | Thread | RE: how XSL processor treat doctype, Kay Michael |
RE: XSL/XSLT components on Wintel, Didier PH Martin | Date | Re: Formatting text output handler , Louis-Dominique Dube |
Month |