[z3-checkins] r10732 - z3/clarity/trunk/xslt
faassen at codespeak.net
faassen at codespeak.net
Sat Apr 16 15:23:14 MEST 2005
Author: faassen
Date: Sat Apr 16 15:23:14 2005
New Revision: 10732
Added:
z3/clarity/trunk/xslt/unescape.xsl
Log:
Imperfect XSLT template which unespaces any < and > it runs into.
This is probably useless, but it's a neat application of misusing
XSLT, so I thought I'd check it in.
Added: z3/clarity/trunk/xslt/unescape.xsl
==============================================================================
--- (empty file)
+++ z3/clarity/trunk/xslt/unescape.xsl Sat Apr 16 15:23:14 2005
@@ -0,0 +1,17 @@
+<xsl:stylesheet
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ version="1.0" >
+ <xsl:output method="text" />
+
+ <xsl:template match="/">
+ <xsl:apply-templates />
+ </xsl:template>
+
+ <xsl:template match="@*"><xsl:text> </xsl:text><xsl:value-of select="name()" />="<xsl:value-of select="." />"</xsl:template>
+
+ <xsl:template match="*"><<xsl:value-of select="name()" /><xsl:copy><xsl:apply-templates select="@*"/>><xsl:apply-templates /></xsl:copy></<xsl:value-of select="name()" />></xsl:template>
+
+ <xsl:template match="comment()"><!--<xsl:value-of select="."/>--></xsl:template>
+
+ <xsl:template match="processing-instruction()"><?<xsl:value-of select="name()" /><xsl:text> </xsl:text><xsl:value-of select="." />?></xsl:template>
+</xsl:stylesheet>
\ No newline at end of file
More information about the z3-checkins
mailing list