I hope somebody can give me a clue on this one. I have a group of
finding aids that I have converted from beta to version 1, XML
format. I would like to do some XSL processing on them, to clean up
some of our earlier variations and encoding errors, and make them
conform more to our new local guidelines. I want the output XML
document to retain the ENTITY declarations in the DOCTYPE and the
entity references in the document, without expanding them.
I was able to use the xsl:output element to create a DOCTYPE in the
output file that matches the one in the source document, but XT
expands the ENTITY references in the output file, and deletes the
declarations from the header. Michael Kay mentions in his book "XSLT"
that the XML recommendation allows for skipped entity references by
non-validating parsers, but that in practice most parsers do expand
all references, and that in XSLT there is an implicit assumption that
they will do so. Also, Dave Pawson suggests a method for inserting an
entity reference into the output document, using the structure
I'm not sure how I would apply this to an existing entity
reference--perhaps with xsl:if? Even so, I would then still need to
post-process the output file to put the ENTITY declarations back into
Any suggestions for me? I was hoping for to be able to better control
the XML->XSL->XML process!
Eric L. Stedfeld
Info Tech Specialist
[log in to unmask]