[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Namespace Aliasing without xsl:namespace-alias

Subject: Re: Namespace Aliasing without xsl:namespace-alias
From: mazerunner@xxxxxx
Date: Tue, 24 Jan 2006 21:23:47 +0100 (MET)
xmlns b xsl
Hi David,

>the behaviour you describe doesn't fit with the way XSLT works, so most
>likely the results you are seeing are from some other part of your
>stylesheet. Can you post a small example of a complete 5 or six line
>document and a similar sized stylesheet that shows the effect, and say
>what result you wanted.

"exclude-result-prefixes" works fine - as Mike Haarman suggested. Thanks!

What is wrong with it? Here an example: I want to transform <root
xmlns="urn">text</root> to <b>text</b>. I can do it with following
stylesheet:

<xsl:stylesheet version="1.0" 
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:B="urn"
  exclude-result-prefixes="B">
  <xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes"/>
    <xsl:template match="*">
      <b>
        <xsl:value-of select="text()"/>
      </b>   
      <xsl:apply-templates select="*"/>
    </xsl:template>
</xsl:stylesheet>

If I don't exclude the namespace I will get following result:
<b xmlns:B="urn">text</b> .

Best regards
Tobias

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.