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

Re: two-phase transformation fails to match with expec

Subject: Re: two-phase transformation fails to match with expected template.
From: Jeroen Hellingman <jeroen@xxxxxxxx>
Date: Tue, 24 Nov 2009 23:17:50 +0100
Re:  two-phase transformation fails to match with expec
Thanks Michael, that did the trick.

Actually, the original was using the http://www.daisy.org/z3986/2005/ncx/ namespace.

Interesting I had to create an explicit prefix for it:

   <xsl:stylesheet
       xmlns="http://www.daisy.org/z3986/2005/ncx/"
       xmlns:ncx="http://www.daisy.org/z3986/2005/ncx/"
       xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
       version="2.0">

<!-- ..... -->

<xsl:template match="ncx:navPoint" mode="playorder">
<xsl:copy>
<xsl:attribute name="playOrder"><xsl:number level="any" count="ncx:navPoint"/></xsl:attribute>
<xsl:apply-templates select="@*|node()" mode="playorder"/>
</xsl:copy>
</xsl:template>


The full, now functional, style sheet is here: http://code.google.com/p/tei2html/source/browse/trunk/tei2ncx.xsl

Jeroen.

Michael Kay wrote:
You created the navPoint element in the namespace
http://www.w3.org/1999/xhtml (which seems a bad idea, but if you do it, then
you need to match it in that namespace).


Regards,

Michael Kay
http://www.saxonica.com/
http://twitter.com/michaelhkay

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-2011 All Rights Reserved.