|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
Here is the XML that I am getting passed to me and what I need to do is be able to create 2 separate variables out of each ADORNMENT element.
<ATTRIBUTE_VALUE attribute_key="price adornment"> <PRICE_ADORNMENTS> <ADORNMENT pos="position1" name="Price 1">299.99</ADORNMENT> <ADORNMENT pos="position2" name="Price 2">500</ADORNMENT> </PRICE_ADORNMENTS> </ATTRIBUTE_VALUE> I have created a variable called priceAdornment and am able to output the contents of the ADORNMENTS.....my output is 299.99 500. <xsl:variable name="priceAdornment"><xsl:apply-templates select='ATTRIBUTE_VALUE[@attribute_key="price adornment"]/PRICE_ADORNMENTS'/></xsl:variable> What I need to be able to do is create a variable for position1 name and value so that I have 2 differnt variable created that represent this element. Can I create a variable that is populated with Price 1 and another tag poulated with 299.99? Thanks |
|
#2
|
||||
|
||||
|
No. Once you have set a variable's value, you cannot change or modify that value!
![]() Try looking at using the <xsl:with-param>.
__________________
mr... mike.rusaw@realpage.com RalPage, Inc. "I have made this letter longer than usual, only because I have not had the time to make it shorter." - Blaise Paschal Last edited by mrusaw : August 5th, 2003 at 05:42 PM. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > XML Programming > XSLT help with variable |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|