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

constructing a "variable" select argument

Subject: constructing a "variable" select argument
From: "Tracey Zellmann" <tracey.zellmann@xxxxxxxxxxx>
Date: Mon, 27 Feb 2006 09:58:06 -0500
construct variable
I have a stylesheet where I need to handle several different situations.
I want to make these selections, for instance

<xsl:value-of select="$questions//Track[@id='T1']/MCP[@id='MC1']/ReportInstructions"/>
<xsl:value-of select="Report/TrackT1/Position[@position='Left Front']/MCHistogram[@id='1']/Average"/>


<xsl:copy-of select="/Report/TrackT1/Position[@position='Left Front']/MCHistogram[@id='1']/svg:svg"/>


In different situations, the value T1 and MC1 change, to say T2 and MC2, and position might be Right Rear.


I am trying to create a template that will handle that, where I could pass in three parameters, say trackId, mcpID, and position and then construct the unique string with concatenation functions, say $selectArgument, and have a statement in the template like
<xsl:value-of select="$selectArgument"/> or
<xsl:copy-of select="$selectArgument"/>
or something like it, that would do the job.


However, I am unsure how to handle the various quotation marks and their escaping, etc.

Could someone point me in the right direction?

Thanks.

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-2007 All Rights Reserved.