Subject: Re: XSLT vs OmniMark From: Louis-Dominique Dubeau <ldd@xxxxxxxxxxx> Date: 07 Mar 2000 07:30:25 -0500 |
Linda van den Brink <lvdbrink@xxxxxxx> writes: > But I was very disappointed to find out that Omnimark's parser doesn't work > with well-formed XML, only valid XML. I needed a tool to transform > well-formed XML so I went back to using XSLT. When I compared the two > languages during the time I was using them both, I felt that XSLT is a > nicer, easier, more intuitive, and more flexible (I'm looking for the right > word here) language to use for precisely the task for which it was built - > transforming XML documents, well-formed or valid. Omnimark can do loads of > other useful stuff very well, though; it's very powerful. I see you like XSLT. Here are further thoughts about this. XSLT by itself might not be able to beat Omnimark but XSLT+[some scripting language] might. So, okay, from an abstract point of view where you compare the different tools by themselves this is "cheating" because it is not just XSLT. However, in real life, this is the kind of solution that can solve a problem without requiring too much money or time. You get XSLT to do most of the work and you do what you can't do with XSLT with a scripting language like Perl or Python. The XSLT stylesheet can even embed markers in the output to help the script that does the final processing. For instance, my resume is now an XML file to which I apply an XSL stylesheet to turn it into HTML, ASCII or PDF (with the help of FOP). (My resume usually serves as my "hello, world" when I learn stylesheet languages: I did the same with DSSSL.) The problem with XSL is that the ASCII version looks terrible if I don't clean it up. So what I do is that for the ASCII version, it outputs only the contents of the tags plus control codes that happen to look like tags. For example, I have <inc> to increase the indentation level and <dec> to decrease it. So this output is piped through a Perl script that interprets the codes and transforms the stream accordingly. It's about one page of code. The output of the script is then piped to "fmt" to do line wrapping and to "recode" to turn iso-8859-1 characters to something acceptable in ASCII. I have started exploring using VB to process the output of my cleanup script to create a nice Word document but I haven't gotten to it yet. Regards, ldd XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: XSLT vs OmniMark, Linda van den Brink | Thread | Re: XSLT vs OmniMark, Rick Geimer |
RTF Files, Paul Paximadis | Date | Re: Dynamic Table Generation, Phil Lanch |
Month |