|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: wordml to docbook (sect1-sect5)
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.
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








