Re: [xsl] stylesheet problem - X3D XSLT

Subject: Re: [xsl] stylesheet problem - X3D XSLT
From: Florent Georges <lists@xxxxxxxxxxxx>
Date: Thu, 29 May 2008 16:48:19 +0200 (CEST)
j milo taylor wrote:

  Hi

> I'm having problems with my stylesheet  and Netbeans can't compile
> it. I can't figure out what I'm doing wrong.

> Netbeans gives me : line 34: Attribute 'url' outside of element.

>                         <Appearance containerField='appearance'>
>                                 <ImageTexture
> containerField='texture' 
> url='"http://localhost/images/artists/Ayers/jpg";'/><!-- what should
> the 
> default value be here?-->
>                                                      <xsl:attribute 
> name="url"><xsl:value-of select="Artist_Image"/> <!--here is the 
> problem?-->
>                        </xsl:attribute>

  You try to add an attribute to an element after having added content
to that element yet.  That is an error.  Use:

    <Appearance ...>
       <xsl:attribute name="url">
          ...
       </xsl:attribute>
       <ImageTexture .../>

instead of:

    <Appearance ...>
       <ImageTexture .../>
       <xsl:attribute name="url">
          ...
       </xsl:attribute>

  Actually, you can also use an AVT in that case:

    <Appearance url="{ ... }" ...>
       <ImageTexture .../>

  Regards,

--drkm























__________________________________________________
Do You Yahoo!?
En finir avec le spam? Yahoo! Mail vous offre la meilleure protection possible contre les messages non sollicitis 
http://mail.yahoo.fr Yahoo! Mail 

Current Thread