Subject: Re: [xsl] stop the processing of default attributes? From: David Carlisle <davidc@xxxxxxxxx> Date: Fri, 19 Aug 2011 00:03:48 +0100 |
that for-each is a verbose way of writing <xsl:copy-of select="@*"/> (apart from some namespace effects)I think I know the answer to this question, but would like to see if I mssied something.
I;m using the following template in my conversion effort. This si teh default handling for any element that I don't have something specific to do on it:
<xsl:template match="*"> <xsl:element name="{name()}"> <xsl:for-each select="@*"> <xsl:attribute name="{name(.)}"><xsl:value-of select="."/></xsl:attribute> </xsl:for-each>
<xsl:apply-templates/> </xsl:element> </xsl:template>
This works great except for places where the element has some default value in the schema. So instead of getting<refdm> as output, I get:
-- google plus: https:/profiles.google.com/d.p.carlisle
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] stop the processing of defaul, dvint | Thread | Re: [xsl] stop the processing of de, Dan Vint |
[xsl] stop the processing of defaul, dvint | Date | Re: [xsl] redirecting ouput to a di, G. Ken Holman |
Month |