On Jan 19, 2005, at 7:29 PM, Marc Salvetti wrote:
nope ! lost your bet, the result is just exactly the same :-\
bummer!
i tried this instead :
<xsl:copy-of select="."> <xsl:if test="$required='true'"> <xsl:attribute name="class">required-field</xsl:attribute> </xsl:if> </xsl:copy-of>
and this copies all the attributes of the <fi:styling> tag to the control (even the type="textarea" which is not supposed to be...) but the class="required-filed" is still not copied !
Well, check the reference on <xml:copy-of>... its contents are always ignored.
Can you show your whole stylesheet? There should be no <fi:styling> element left by the time you get to the "custom-styling" moded template, because we're invoking it on the result of applying the imported template which has already translated the fi:* to HTML.
Then i wonder (again) if we are matching the correct element. I think maybe we are matching the fi:field element where we should match the fi:styling... or the opposite :-D
We _do_ want to match fi:field — in the wrapper template (the one that does the <apply-imports>). This template has mode="styling", so it only matches for <apply-templates mode="styling">.
But I think I see the problem... we're also going to match all kinds of other stuff for which there are specific templates in forms-field-styling. My bad again! So the wrapper template should match="fi:field", not fi:*. Give that a try... but if it doesn't work, let's have a look at your whole stylesheet! :-)
GL, —ml—
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
