Subject: RE: [xsl] Using an XSLT value as a HTML parameter From: "Carlos Fragoso Mariscal" <cfragoso@xxxxxxxx> Date: Sat, 15 Sep 2001 19:10:20 +0200 |
You can define an element name and then attributes that are nodes of the origin xml file. Something like this <xsl:template match="text"> <xsl:element name="font"> <xsl:attribute name="@format"> <xsl:value-of select="@value"/> </xsl:attribe> </xsl:element> </xsl:template> I don't know if @format goes with {} or not, have a try. I hope it helps you. -------- Carlos Fragoso Mariscal <cfragoso@xxxxxxxx> -----Mensaje original----- De: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx [mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]En nombre de J.Brown (Ender/Amigo) Enviado el: viernes, 14 de septiembre de 2001 6:38 Para: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Asunto: [xsl] Using an XSLT value as a HTML parameter Hey all. I'm trying to do something similar to this: (xml) <text format="color" value="#113344"> (/xml) (xsl) <xsl:template match="text"> <font "{./@format}"="{./@value}"> <xsl:apply-templates/> </font> </xsl:template> (/xsl) Alternativly a way to simply say <text color="#1111111"> without having to put in a large number of ifs (as the color tag may be something different) would be neat :) TIA! - Ender XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Using an XSLT value as a HTML, J.Brown (Ender/Amigo | Thread | RE: [xsl] Using an XSLT value as a , Wendell Piez |
[xsl] Array XSL PROb, P Vikram | Date | [xsl] RE:, Carlos Fragoso Maris |
Month |