[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: wordml to docbook

Subject: Re: wordml to docbook
From: Jon Gorman <jonathan.gorman@xxxxxxxxx>
Date: Tue, 6 Dec 2005 12:03:48 -0600
wordml create element
> yes you are right!
> i can transform all the elements inside of <p>...</p>
> and i can create the sect1 but my problem is now,
> if style="level1" i create <sect1> and all elemets which are
> inside of this <p>-tag shoud be inside.When the style"level2" comes
> i want to open a <sect2> inside of <sect1> and all elements of
> this <p>-tag with level2 should be inside and so one...and this
> opening of <sect2> without closing <sect1> is my problem!
>
Like I said, I think you're going around this the wrong way...stop
thinking about tags.  You're taking a SAX approach to this problem.
What you want to do is for each level one element in the input, create
a new section 1 and apply templates within this new element to all
nodes in source between the current element and the next level 1.  Do
this recursively or via keys.  It's a standard grouping problem (as
well as a standard flat xml file problem).  The faq addresses a lot of
the concerns you mentioned.  It also can be a bit complex to
implement, but it's not a new problem in any sense of the word.  I'd
be surprised if you can't find some similar transforms of word xml
already to base as examples.

Instead of getting all confused with the word xml file format why
don't you try using simpler XML and then progressively increase the
complexity of the sample docs.  If you follow the advice given it
should scale well.


Jon Gorman

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.