Subject: Moded Templates
From: "Lopez, William" <william.lopez@xxxxxxx>
Date: Mon, 6 Jan 2003 12:44:17 -0600
|
Hello:
After looking at the spec ( http://www.w3.org/TR/xslt#modes ) and searching
the "biglist", I could not find the answer to my question. Besides a
"qualified name" what other values can be used when specifying a mode, is
there a way to define a template using an 'or' (|) or a wildcard (*), for
example, I want template A, B, and C to be used all the time but only need
template D & E when the specific mode is needed. What I'm trying to
accomplish is minimize the number of stylesheets I create- I want 1
stylesheet to contain all the functionality versus having multiple
stylesheets (with duplicated code).
So the XSL would look something like this:
<xsl:template match="A" mode="*">
...
</xsl:template>
or
<xsl:template match="A" mode="(A|B|C)">
...
</xsl:template>
<xsl:template match="B" mode="*">
...
</xsl:template>
<xsl:template match="C" mode="*">
...
</xsl:template>
<xsl:template match="D" mode="MODE_X">
...
</xsl:template>
<xsl:template match="E" mode="MODE_Y">
...
</xsl:template>
Thanks!
Will Lopez
EDS - Health & Insurance Application Solution Centre
MS C3-1C-37
5400 Legacy Drive
Plano, TX 75024
( phone: +01-972-604-3372 (834-3372)
/ william.lopez@xxxxxxx
8 www.eds.com
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
| Current Thread |
- Moded Templates
- Lopez, William - Mon, 6 Jan 2003 13:43:57 -0500 (EST) <=
- <Possible follow-ups>
- Lopez, William - Mon, 6 Jan 2003 16:21:51 -0500 (EST)
|
|