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

Re: X3D XSLT - re yesterday

Subject: Re: X3D XSLT - re yesterday
From: David Carlisle <davidc@xxxxxxxxx>
Date: Fri, 30 May 2008 12:32:40 +0100
Re:  X3D XSLT - re yesterday
> I now get no "Attribute 'url' outside  of element. null" error

however



<xsl:template match="Artist_Image">

This template is inside the   <xsl:template match="artists"> so that's a
syntax error, you can't nest templates. But if you moved it out to the
top level then 

       <Shape containerField='children'>
         <xsl:for-each select="Artist_Image">

                        <Appearance containerField='appearance'>
                                 <xsl:attribute name="url">
                              <xsl:value-of select="Artist_Image"/>

so you are matching on Artist_Image, then iterating over all it's
Artist_Image children and for each such child using the value of its
Artist_Image child as the url.

So this will only select anything if your input has three nested levels
of Artist_Image





<Artist_Image>
  <Artist_Image>
    <Artist_Image>some url value</Artist_Image>
  </Artist_Image>
</Artist_Image>



saxon gives the rather more helpful messages on your stylesheet

$ saxon9 -versionmsg:off 3d.xsl 3d.xsl
Error at xsl:template on line 31 of file:/c:/tmp/3d.xsl:
  XTSE0010: An Transform element must not contain an xsl:template element
Error at xsl:template on line 31 of file:/c:/tmp/3d.xsl:
  XTSE0010: Element must be used only at top level of stylesheet
Failed to compile stylesheet. 2 errors detected.


David

________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs. 
________________________________________________________________________

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.