Lists Home |
Date Index |
- From: James Robertson <email@example.com>
- To: firstname.lastname@example.org
- Date: Sat, 16 Dec 2000 09:49:51 +1100
At 23:28 15/12/2000, Michel Rodriguez wrote:
>I have a problem, and I would like to know if there is any way to solve
>it in a generic, XML clean way. I would be particularly interested in
>knowing whether XSLT could be up to the task.
>I am converting files from a word processor format (MIF) to XML.
>I use a 2-pass process: first go from MIF to a first XML file then from
>this to the final XML file.
>The first pass, essentially consists in turning each character or
>paragraph style in the original file into a an element. The result is a
>"flat" XML file: it lacks the "superstructure" of enclosing XML elements
>(list items are tagged as such but lists are not for example).
>The second pass is then of course to wrap those elements around the low
>level ones. And this is the one that's causing me problems.
>I would like to use a mechanism similar to what Frame does with their own
>"Conversion Tables": using a table to describe the content of wrapping
>tags with a regexp-like syntax.
>The example below uses a table like:
> officers : person[officer]+
> perslist : officers, person+
>But my real software uses rules as complex as
> stdtitle : stddes*, stddesmo?, reaf?, stdcoll?, titlemod?, rev?, title+
I would strongly recommend Omnimark for this
job. This is bread-and-butter work for an Omnimark
program (which combines both regular-expressions and
Step Two Designs Pty Ltd
SGML, XML & HTML Consultancy
Illumination: an out-of-the-box Intranet solution