Re: [xsl] How to output attribute without namespace

Subject: Re: [xsl] How to output attribute without namespace
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Fri, 7 Sep 2001 09:25:56 +0100
Hi Dmitri,

> It works.But the problem that i have is i don't know the local-name
> of attribute....

You can work out the local name of an attribute with the local-name()
function.  Try:

<!-- match all attributes in the param namespace -->
<xsl:template match="@param:*">
  <!-- create an attribute of that name in no namespace -->
  <xsl:attribute name="{local-name()}">
    <xsl:value-of select="." />
  </xsl:attribute>
</xsl:template>

I hope that helps,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread