Subject: Re: [xsl] wordml to docbook (sect1-sect5) From: Jon Gorman <jonathan.gorman@xxxxxxxxx> Date: Tue, 6 Dec 2005 09:05:49 -0600 |
I think you're making the problem more complicated than it actually is. Remember, XSLT isn't about "closing tags" and end tags. It's about using functional approaches to manipulating a node tree. This is somewhat of a generalization, but not an extreme one. This seems to be just a variation of the the FAQ of node depth: http://www.dpawson.co.uk/xsl/sect2/N2193.html. So what you might want to do is to count the number of ancestor::w:p or whatever you're creating the source from. that is <xsl:variable name="level" select='count(ancestor::w:p) + 1' /> <xsl:element name="sect{$level}"> ... </xsl:element> Or am I missing somthing? Jon Gorman ps. This is a bit of a pet peeve of mine, but I follow these messages based on subject line/thread. So if you're going to add information when you have a currently existing thread, do it there, don't start a new one. No one has responded to your email so I figure you might still need a response, but I don't like having to jump around a couple of threads to do it.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] wordml to docbook, Steve Ball | Thread | Re: [xsl] wordml to docbook (sect1-, Steve Ball |
Re: [xsl] use two consecutive trans, mus47@xxxxxxxx | Date | Re: [xsl] How can I create a variab, Ferdinand Soethe |
Month |