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

One var to concat strings, one var to call ext. function

Subject: One var to concat strings, one var to call ext. function
From: dkarr@xxxxxxxx (David M. Karr)
Date: 10 Nov 2000 12:51:12 -0800
concat strings c
I have a template that sets one variable called "domainClass", then I
need to set several other variables to represent display labels
associated with fields.  I'm using a Xalan extension function to read
the display label out of a properties file.

I'm trying to make the code for getting the display label as concise
as possible.  So far, I'm left with things like the following:

 <xsl:variable name="niSessionIdKey"
               select="concat('xsl.',$domainClass,'.NISessionId.text')" />
 <xsl:variable name="niSessionIdLabel"
               select="pm:get($niSessionIdKey)" />

Then, when I need the display label, I use:

 <xsl:value-of select="$niSessionIdLabel"/>

If I have ten labels, then I need twenty variables.  For each pair of
variables, I really only need the second one.  I declared the first
one because I couldn't figure out how to combine them. Is it possible
to wrap the "pm:get()" around the "concat()" call so I just have a
single variable?

-- 
===============================================================================
David M. Karr     ; dkarr@xxxxxxxx  ; w:(425)487-8312 ; TCSI & Best Consulting
Software Engineer ; Unix/Java/C++/X ; BrainBench CJ12P (#12004)


 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.