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

<xsl:copy> does not work as expected (xalan 1.1 c++)

Subject: <xsl:copy> does not work as expected (xalan 1.1 c++)
From: Gus Tenrreiro <gus@xxxxxxxxxxx>
Date: Thu, 24 May 2001 11:42:57 -0700
vxml c
Hi everybody,
                I am trying to do something very simple, I just need to add
an attribute to a node in my xml file. But to start simple I just tried to
make the exact copy of the xml file using <xsl:copy> on each element, but
the result is not as expected.

 my xml file looks like this:
 <?xml version="1.0" ?> 
 <vxml version="1.0"> 
  <form id="noname"> 
   <block> 
     <prompt> 
         <audio src="http://myMachine/GG010101.au" /> 
         <audio src="http://myMachine/GG010102.au" /> 
    </prompt> 
 </block> 
 <field name="Result"> 
       <grammar src="http://myMachine/.GG_SELECT_TRACK.grammar"
caching="safe" /> 
       <filled> 
               <submit next="http://myMachine/run?SESSIONID=11565472"
method="POST" namelist="Result" /> 
       </filled> 
</field> 
 </form> 
</vxml>

and this is my xsl file

<?xml version="1.0"?> 
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">

<xsl:template match="@* | node()">
   <xsl:copy>
      <xsl:apply-templates select="@* | node()"/>
   </xsl:copy>
</xsl:template>

</xsl:stylesheet>

and this is the output

<vxml>
   <form>
       <block>
          <prompt>
              <audio src = "http://63.198.37.44/gartner/GG010101.au"/>
              <audio src = "http://63.198.37.44/gartner/GG010102.au"/>
          </prompt>
        </block>
        <field>
            <grammar src =
"http://63.198.37.44/gartner/.GG_SELECT_TRACK.grammar" caching = "safe"/>
            <filled>
                <submit next =
"http://63.198.37.44/gartner/run?SESSIONID=11565472" method = "POST"
namelist = "Result"/>
            </filled>
        </field>
    </form>
</vxml>


The form's id attribute disapears, same with the field's name attribute.
Why??????????

Thanks

Gustavo E Tenrreiro

gus@xxxxxxxxxxx

work: (650) 413-5565
cell  : (408) 373-8595
home: (408) 225-7097







 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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.