xsl-list
[Top] [All Lists]

Re: [xsl] testing for position of an element and displaying it accordingly

2007-01-25 12:06:01
Hi David:

That is exactly the problem I am facing. Since apply templates matches
everything, the "steps" template has <xsl:apply-templates
select="a"/>, and has <xsl:apply-templates> at the end of
<fo:list-body>

As a result, it repeats the <a> before <text> and after <text> twice. So I get:

Some test
Some other test
Some test 3
1. This is level1
Some test
Some other test
Some test 3

Please do help me resolve this.



On 1/25/07, David Carlisle <davidc(_at_)nag(_dot_)co(_dot_)uk> wrote:


as has been stated before

<xsl:if test="a">
<xsl:apply-templates select="a"/>
</xsl:if>


is ___exactly__ the same thing as


<xsl:apply-templates select="a"/>


and this causes all a elements to be processed at this point, out of
their natural order. If you didn't do this your problem would go away.

David


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--