|
Subject: Re: [xsl] Converting XHTML to FO using XHTML2FO.xsl From: David Carlisle <davidc@xxxxxxxxx> Date: Thu, 19 Oct 2006 20:44:23 +0100 |
> match="br[ancestor::p or ancestor::li][position()=last()]"
That would match a br under a p or li that's the last br of its parent
(not the last br in the p or li). I think the OP wanted
*[self::p or self::li]/decendant::br[last()]
that would select the right elements but isn't a legal pattern, using //
instead of descendant:: would be a pattern but suffer from the same
problem as the quoted expression,
one way to do this as a pattern would be
match="key('b',generate-id(ancestor::*[self::p or
self::li][1]))[last()])"
<xsl:key name="b" match="br[ancestor::p or ancestor::li]"
use="generate-id(ancestor::*[self::p or self::li][1])"/>
<xsl:template
match="br[generate-id()=generate-id(key('b',generate-id(ancestor::*[self::p
or self::li][1]))[last()])]">
David
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: [xsl] Converting XHTML to FO us, J.Pietschmann | Thread | [xsl] Another (positional?) groupin, Rudolf P . Weinmann |
| [xsl] XSLT and XSL-FO book updates , G. Ken Holman | Date | [xsl] Help with mode, Meenakshi Nanjundesw |
| Month |