[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
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
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|