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

get the value from a different child

Subject: get the value from a different child
From: Nicola Cubeddu <cubo@xxxxxx>
Date: Thu, 04 May 2000 10:25:11 +0100
nicola cubeddu
Hello, I have a XML like this,

<LIST>
  <ATTRIBUTE>
    <PERMISSION>1</PERMISSION>
    <NAME>Cs</NAME>
  </ATTRIBUTE>
...
  <BILLING_ATTRIBUTE>
    <VALUE>3111</VALUE>
    <NAME>Cs</NAME>
  </BILLING_ATTRIBUTE>
...
</LIST>

I want a <INPUT TYPE="TEXT">
with name= ATTRIBUTE . NAME
and with value= BILLING_ATTRIBUTE . VALUE

can anyone say me why this XSL do NOT work?

<xsl:template match="ATTRIBUTE[PERMISSION='1']">
  <TR>
    <TD>
      <xsl:value-of select="NAME"/>
    </TD>
    <TD>
     <INPUT TYPE="TEXT">
        <xsl:attribute name="NAME"><xsl:value-of select="NAME"/></xsl:attribute>
        <xsl:variable name="myName"><xsl:value-of select="NAME"/></xsl:variable>

        <xsl:attribute name="VALUE">
           <xsl:value-of select="BILLING_ATTRIBUTES[NAME=$myName]"/>
        </xsl:attribute>
     </INPUT>
 ...

I appreciate all comment.
ciao ciao
 

NICOLA CUBEDDU
Consultancy & Projects Group
Via Mameli, 228
09123 Cagliari - ITALY
 

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.