Subject: Re: [xsl] Getting a sequence of attribute names From: "Rick Quatro rick@xxxxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Wed, 17 Jul 2019 18:15:46 -0000 |
Excellent, Martin, thank you! I was trying local-name(@*), which didn't work. Thank you for the fast response. From: Martin Honnen martin.honnen@xxxxxx <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> On 17.07.2019 20:03, Rick Quatro rick@xxxxxxxxxxxxxx wrote: > For each of the <em> elements, I am trying to get a space-delimited > list (or string) of attribute names. For example, the first one would > be "italic" and the second would be "italic bold". My output would be > similar to this: > > <?xml version="1.0" encoding="UTF-8"?> > > <root> > > <p> > > <em class="italic">first paragraph</em> > > </p> > > <p> > > <em class="italic bold">second paragraph</em> > > </p> > > </root> <xsl:template match="em[@*]"> <em class="{@*/name()}"> <xsl:apply-templates/> </em> </xsl:template> should do.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Getting a sequence of att, Martin Honnen martin | Thread | Re: [xsl] Getting a sequence of att, Christoph Naber pent |
Re: [xsl] Getting a sequence of att, Martin Honnen martin | Date | Re: [xsl] Getting a sequence of att, Christoph Naber pent |
Month |