This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Q XSLT: How to copy elements with XT?


Vit,

   I am copying (x)html, too. Here is the basics of what I do:

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes" omit-xml-declaration="yes">

<xsl:template match="/">
  <xsl:apply-templates/>
</xsl:template>

<xsl:template match=" a | applet | b | big | body | br | caption | cite | code | col | colgroup | dd | div | dl | dt | em | font | form | frame | frameset | head | h1 | h2 | h3 | h4 | h5 | h6 | hr | html | i | iframe | img | link | li | map | meta | noframes | ol | p | param | pre | s | script | small | span | strong | style | sub | sup | td | th | title | tr | tt | ul | var | table ">
  <xsl:copy>
    <xsl:copy-of select="@*"/>
    <xsl:apply-templates/>
  </xsl:copy>
</xsl:template>

<!-- ADD YOUR template here -->

</xsl:output>
</xsl:stylesheet>

While this doesn't look too elegant, it copies the html and it
does something else with the other stuff.

Hope this helps,

Joerg
_______________________________
Dr. Joerg M. Colberg
Econovo Software Inc.
joerg.colberg@econovo.com


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]