|
Subject: Re: [xsl] Append Attribute From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx> Date: Sun, 14 Nov 2004 09:03:29 -0500 |
Using xsl:attribute (or similar), is there a way to append an attribute to an existing attribute set?
Example: <div class="my_div"> <xsl:attribute name="class">big_font</xsl:attribute> </div>
Desired Output: <div class="my_div big_font"> </div>
<div>
<xsl:attribute name="class">
<xsl:text>my_div</xsl:text>
<xsl:if test="$mytest">
<xsl:text> big_font</xsl:text>
</xsl:if>
<xsl:if test="$myothertest">
<xsl:text> other_property</xsl:text>
</xsl:if>
</xsl:attribute>
...
</div>-- World-wide on-site corporate, govt. & user group XML/XSL training. G. Ken Holman mailto:gkholman@xxxxxxxxxxxxxxxxxxxx Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/ Box 266, Kars, Ontario CANADA K0A-2E0 +1(613)489-0999 (F:-0995) Male Breast Cancer Awareness http://www.CraneSoftwrights.com/s/bc Legal business disclaimers: http://www.CraneSoftwrights.com/legal
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: [xsl] Append Attribute, xptm | Thread | [xsl] XML to HTML table, Modha Kumar |
| Re: [xsl] Nested loops, Peter Bradley | Date | Re: [xsl] document(), Geert Josten |
| Month |