OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: How can I render an element twice without duplicating the ID?

Hello all,

I am working on stylesheets for a book that will have Q/As and
task-descriptions in it. I want to display the <qandaentry>s without
<answer>s, and the task <step>s without <example>s by default, then
reprint each element in its entirety (ie with answers and examples) in
an appendix at the end.

The approach I'm taking is to override the templates for qandaentry
and step so that they omit the "answer" elements by default, then
create mode="answers-section" templates for them that do include the
answers, and call those at the end of the book template.

The problem I am encountering is that the default fo output
stylesheets, upon which I'm basing mine, add id elements to nearly
everything, it seems, and generate-id() always seems to generate the
same value when run against the same element, even if it's being run a
second time. I've even tried using <xsl:copy-of> to avoid duplicating
IDs, and so far no luck (though I might just not be using it right
yet), and since fop dies if there are two elements with the same ID,
building a pdf fails.

So, I my questions are:
1) Is this a sane way to go about what I want to accomplish?
2a) If so, how can I avoid getting duplicate IDs?
2b) If not, suggestions?


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]