[Home] [By Thread] [By Date] [Recent Entries]
On 21/12/2010 12:30, Matthieu Ricaud-Dussarget wrote:
<p foo="foo_att" bar="bar_att" foobar="foobar_att">my text</p><xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="*" mode="x">
<xsl:param name="a" select="@*"/>
<xsl:choose>
<xsl:when test="exists($a)">
<xsl:element name="{name($a[1])}">
<xsl:apply-templates select="." mode="x">
<xsl:with-param name="a" select="$a[position()!=1]"/>
</xsl:apply-templates>
</xsl:element>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates/>
</xsl:otherwise>
</xsl:choose>
</xsl:template></xsl:stylesheet>
|

Cart



