Re: [xsl] How to render TEI <div*>s with chapter-like pagination?

Subject: Re: [xsl] How to render TEI <div*>s with chapter-like pagination?
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Thu, 10 Apr 2003 18:14:23 -0400
At 03:17 PM 4/10/2003, you wrote:
The problem I see with this is that, if I read it
right, it would put whatever stuff that may be in
between <div>s, like <milestone/> tags, out in front
of the <div>s instead.

Yes, that's correct. *Sigh*, milestones. The real world is such a pain!


I did have an idea of my own, though I'm not sure how
fragile it is. <div*>s are not allowed outside
<front>, <body>, or <back> tags. So, if those tags
always render as <fo:page-sequence> . . .
</fo:page-sequence>, then making it so that something
like "</fo:page-sequence><fo:page-sequence>" is output
at the beginning of every top-level <div> except the
first should do what I want. The main catch that I see
is that one has to do something ugly like <xsl:text
disable-output-escaping="yes">&lt;/fo:page-sequence&gt;</:xsl:text>,
etc., since XSLT doesn't allow ill-formed XML inside
templates.

Yes, and this is generally to be avoided if at all possible. It introduces a dependency on a serialization directly after the transform before the result can be processed again. If this sounds subtle, it is. (And it can be as bad, or worse, than it is subtle. And there are other reasons not to do it.)


Rather than resort to this, I'd first ask where you want your milestones appearing between divs to be processed? (What page sequence should they be in?) Having an answer to this might make the problem go away, or might prompt a workaround.

Cheers,
Wendell






__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - File online, calculators, forms, and more
http://tax.yahoo.com

XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list


======================================================================
Wendell Piez                            mailto:wapiez@xxxxxxxxxxxxxxxx
Mulberry Technologies, Inc.                http://www.mulberrytech.com
17 West Jefferson Street                    Direct Phone: 301/315-9635
Suite 207                                          Phone: 301/315-9631
Rockville, MD  20850                                 Fax: 301/315-8285
----------------------------------------------------------------------
  Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================


XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list



Current Thread