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

RE: With Saxon7.2, can an aliased namespace prefix be

Subject: RE: With Saxon7.2, can an aliased namespace prefix be excludedfrom the output?
From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx>
Date: Thu, 14 Nov 2002 19:46:24 -0000
prefix be
Saxon's output when you use xsl:namespace-alias is inelegant but the
stylesheet that it produces is precisely equivalent to the one that you
want.

It will be improved in the next version.

Michael Kay
Software AG
home: Michael.H.Kay@xxxxxxxxxxxx
work: Michael.Kay@xxxxxxxxxxxxxx 

> -----Original Message-----
> From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx 
> [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of 
> Timothy Larson
> Sent: 14 November 2002 18:28
> To: XSL-List@xxxxxxxxxxxxxxxxxxxxxx
> Subject:  With Saxon7.2, can an aliased namespace prefix 
> be excludedfrom the output?
> 
> 
> With Saxon version 7.2, I am trying to apply a stylesheet to 
> a stylesheet. Is there any way to exclude the aliased 
> namespace prefix from the output?
> 
> In the sample below I am trying to get rid of the output line:
>   xmlns:x="http://www.w3.org/1999/XSL/Transform" 
> 
> Sample source stylesheet:
> 
> <?xml version="1.0"?>
> <xsl:stylesheet version="2.0"
>   xmlns:xsl  = "http://www.w3.org/1999/XSL/Transform">
> </xsl:stylesheet>
> 
> Sample stylesheet to apply to the source stylesheet:
> 
> <?xml version="1.0"?>
> <xsl:stylesheet version="2.0"
>   xmlns:xsl  = "http://www.w3.org/1999/XSL/Transform"
>   xmlns:x    = "http://www.w3.org/1999/XSL/TransformAlias"
>   exclude-result-prefixes="x">
>   <xsl:namespace-alias stylesheet-prefix="x" result-prefix="xsl"/>
>   <xsl:template match="/">
>     <xsl:copy>
>       <x:stylesheet>
>         <x:template m="/"><x:value-of select="test"/></x:template>
>       </x:stylesheet>
>     </xsl:copy>
>   </xsl:template>
> </xsl:stylesheet>
> 
> Output produced:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <xsl:stylesheet
>   xmlns:x="http://www.w3.org/1999/XSL/Transform" 
>   xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
>   <xsl:template m="/"><xsl:value-of 
> select="test"/></xsl:template> </xsl:stylesheet>
> 
> Output disired:
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <xsl:stylesheet
>   xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
>   <xsl:template m="/"><xsl:value-of 
> select="test"/></xsl:template> </xsl:stylesheet>
> 
> 
> 
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
> 


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


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.