I'm trying to create a stylesheet that will output a document as a series of 5x8 cards. They want the front and back of the card to have the same page number (so when you print it out, the first card is "Card A" and shows "Card A" on the front and back). But they don't want to have to author each card as its own element. I can't for the life of me figure out how to implement it without dealing with Area Trees or manually tagging individual cards.
Is there something I'm missing?
Edited to add:
Each "card" is the front and back of a 5x8 pageset so that when it's printed on card stock, you get the same card number. The source data would look something like:
<card>
<header>[...]</header>
<step>Do this</step>
<step>Do that</step>
</card>
<card>
<header>[...]</header>
<step>Do this</step>
<step>Do that</step>
[...]
<step>You've done enough steps that it's overflowed onto another card</step>
</card>
In that scenario, the first card element creates Card A and with only a couple steps, the back of Card A would be blank. The second card element would create Card B, which would have text on the front and back (and the back would still be labelled as Card B) and then the extra text would flow onto Card C.
I can't count the individual elements because the overflow may create more physical cards than there are card elements. And I can't use fo:page-sequence because it wants to number the back of the cards separately.
Assuming that there's a series of some element that generates one card for each element, use
xsl:number(XSLT 1.0: https://www.w3.org/TR/1999/REC-xslt-19991116#element-number) withformat="A"to generate theA, etc. for each card based on the current element's position in the sequence.