listing footnotes

D

David Schwartz

I've got a set of footnotes at the root which are being referenced
elsewhere in the tree via footnot-accoc elements. Footnote-assoc may
occur mutliple places/levels within the tree. I want to number the
footnote reference based on the footnote-assocs within each bucket.
FYI, I use <apply-templates/> extensively in my XSL stylesheets and,
if possible, I'd like to avoid passing a node set everytime.

<root>
<footnotes>
<footnote id="foot-001">
foo
</footnote>
</footnotes>
<bucket>
<description>
<para>Blah, blah<footnote-assoc>foot-001</footnote-assoc></para>
<bullet-group>
<bullet>
<bullet-para>hah<footnote-assoc>foot-001</footnote-assoc>,
hah, hah, hah</bullet-para>
</bullet>
</bullet-group>
</description>
</bucket>
</root>

TIA,
David
 
J

Joseph Kesselman

It'd be a lot easier if you were willing to number the footnotes, and
accept that they may be referenced out of numeric order in the document;
that would let you just use the number of footnotes preceeding this one.

If you really want to assign the numbers in the order in which they
appear in the description... I suspect you're going to get into
Meunchian-like processing to gather all the first-references in order
and bind them to the values.

Before trying to invent this, I'd suggest checking the XSLT FAQ to see
if some has already solved it. It feels like something which is both
common enough, and messy enough, to have been posted there.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,008
Messages
2,570,269
Members
46,869
Latest member
TresaMcGir

Latest Threads

Top