[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: transform only a section of xml
<xsl:template match="* | @*"> <xsl:copy><xsl:apply-templates select="* | @* /></xsl:copy> </xsl:template> <xsl:template match="form"> <form method="post"> <input type="text" name="NAME"/> </form> </xsl:template> Should do the trick... B -----Original Message----- From: Noel Golding [mailto:noel@xxxxxxxxxxxxxxx] Sent: 11 November 2002 16:24 To: XSL-List@xxxxxxxxxxxxxxxxxxxxxx Subject: transform only a section of xml I am sure this is a FAQ but I am not sure how to ask this question properly without illustrating it. I would like to transform only a portion of an xml document while mainting the rest of the structure. <!-- original --> <xml> <section> <title>title</title> <para> <form id="1"/> <!-- item to transform --> </para> </section> </xml> <!-- transform to --> <xml> <section> <title>title</title> <para> <form method="post"> <input type="text" name="NAME" /> </form> </para> </section> </xml> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
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
|