Subject: tricky xsl pattern From: "Mattias Konradsson" <preacher@xxxxxxxxxxx> Date: Sat, 16 Oct 1999 23:12:13 +0200 |
ok, I've been pondering this problem for a while, perhaps someone can help me :) I have an article format that looks roughly like this <article> <metadata> <author>Mattias</author> </metadata> <content> <section> some text here </section> <section> some more text here </section> <section> even more text here </section> </content> <article> using msxml and ie5 you're suppose to be able to view this article page by page (the pages being the section tags), in xsl I'm doing this by having <xsl:apply-templates select="section[0]"/> and then using the XML DOM setting it to section[1], section[2] or whatever, no problem. The thing im stumbling on is that at the end of the section there's suppose to be information displayed from the metadata tag, and as it is now that information gets displayed on every page instead of just the last one, and I can't do something like <xsl:if test="context() [end()]"> because the tree contains only one section node because of the earlier template, thus it's in effect for every page. I need a filter that like, checks how many sections there are totally in the document, what the current section being processed is and if it's the last insert that information, but I'm not sure how to retrieve the numbers of sections while in the section template, context() or something, heck I dunno. If someone made any sense of that and could help I'd be immensely grateful :) ------------------ Mattias Konradsson XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: XSL:FO: Left ... Center ... Ri, Nikolai Grigoriev | Thread | Help with matching, Leigh Dodds |
XSL:FO: Left ... Center ... Right, Sebastian Rahtz | Date | Re: XSL:FO: Left ... Center ... Ri, Steve Schafer |
Month |