Subject: Re: [xsl] Setting a foreign attribute From: "G. Ken Holman" <gkholman@xxxxxxxxxxxxxxxxxxxx> Date: Sat, 31 Oct 2009 17:22:42 -0400 |
FOP does not like this fragment and calls <xsl:use-attribute-sets> a foreign attribute.
<fo:block>
<xsl:choose>
<xsl:when test="parent::Item">
<xsl:attribute name=" xsl:use-attribute-sets">article0</xsl:attribute>
</xsl:when>
<xsl:when test="parent::Level1">
<xsl:attribute name=" xsl:use-attribute-sets">article1</xsl:attribute>
</xsl:when>
<xsl:when test="parent::Level2">
<xsl:attribute name=" xsl:use-attribute-sets">article2</xsl:attribute>
</xsl:when>
<xsl:when test="parent::Level3">
<xsl:attribute name=" xsl:use-attribute-sets">article3</xsl:attribute>
</xsl:when>
</xsl:choose>
..... </fo:block>
Is there a way to set <xsl:attribute-sets> similar to my unacceptable construction, or do I have to create all six attributes for each <xsl:when>?
<xsl:attribute-set name="article0"> ... </xsl:attribute-set>
<xsl:template name="article0"> ... </xsl:template>
<fo:block xsl:use-attribute-sets="article0"> ...
<fo:block> <xsl:call-template name='article0'/> ...
-- Upcoming: hands-on XSLT, XQuery and XSL-FO Washington DC Nov 2009 Interested in other classes? http://www.CraneSoftwrights.com/s/i/ Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/ Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video Video lesson: http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18 Video overview: http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18 G. Ken Holman mailto:gkholman@xxxxxxxxxxxxxxxxxxxx Male Cancer Awareness Nov'07 http://www.CraneSoftwrights.com/s/bc Legal business disclaimers: http://www.CraneSoftwrights.com/legal
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Setting a foreign attribute, Mark Wilson | Thread | Re: [xsl] Setting a foreign attribu, Mark Wilson |
Re: [xsl] copy attributes, except s, ac | Date | Re: [xsl] Setting a foreign attribu, Mark Wilson |
Month |