Re: [xsl] DOCTYPE

Subject: Re: [xsl] DOCTYPE
From: Edierley Messias <edierley@xxxxxxxxxxx>
Date: Wed, 17 Jan 2001 11:32:11 -0200 (EDT)
On Tue, 16 Jan 2001, Mike Brown wrote:
>Edierley Messias wrote:
>> In my xml document a have the doctype declaration:
>> --------------------------------------------------------------------
>> <?xml version="1.0"?>
>> <!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "";>

Hi people and Mike, 
I'm using xalan like:
java org.apache.xalan.xslt.Process -in deck.wml -xsl copy.xsl

I'm trying to copy the deck.wml (xml file) to another xml file only
changing some nodes. In fact I already did that, but the processor,
expands the <!DOCTYPE> declaration to the DTD definiton pointed by the

I saw the xsl:output instruction, but I only wants to copy the <!DOCTYPE>,
not expanding it.

Have some way to do this in Xalan?

My xsl have the classic template to copy all nodes in the document:
<xsl:template match="@*|node()">
    <xsl:apply-templates select="@*|node()"/>

I believe that will copy all nodes, including <!DOCTYPE>, but I just want
to copy, not to expand it.

Thanks in advance people.


>I thought Xalan was an XSLT processor that relied on an XML parser like
>Xerces to do the dirty work of parsing the XML and XSLT documents it
>processes. How exactly are you making Xalan do this?
>It isn't wrong for an XML parser to go look at the remote DTD, but it is
>wrong for it to actually insert it into the XML. How did you accomplish
>What are you trying to do, anyway? Transform the XML to something else?
>Are you trying to create a <!DOCTYPE> in your output? There are attributes
>in the xsl:output instruction for achieving that.
>   - Mike
>Mike J. Brown, software engineer at            My XML/XSL resources: 
> in Denver, Colorado, USA    
> XSL-List info and archive:

Edierley Messias
icq 32943484

 XSL-List info and archive:

Current Thread