Re: [xsl] MSXSL in Java (server pages)

Subject: Re: [xsl] MSXSL in Java (server pages)
From: Barry Lay <blay@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 29 Apr 2005 11:33:49 -0400
Woody,

When I first read this I thought that you might want to run a transform in Java with a stylesheet with embedded Javascript. Mozilla has something called Rhino that helps with this but there is a lot of playing around with versions of Xalan, Xerces, Rhino, etc., to get it to work. That would require that the stylesheets were otherwise XSLT 1.0 compliant. I don't remember which version of MSXML represented the change over to this spec but earlier versions used a somewhat different language that won't work in a modern transformer.

If all you want to do is run MSXML from a JSP you can exec it and it should run in another process. You will have to be running your server on a Windows platform of course and will also have to communicate via the filesystem unless you can wrap the MSXML in something that will talk to standard in/out. Either way you will have to serialize the XML and deserialize the result.

Barry

Woody wrote:

I know the immediate answer is 'don't', but I have 4 weeks to do a proof of concept on a web version of a product that displays documents which are created via MSXSL.
The xsl that I have written over the last few years will run on any xml processor, but the older stuff is full of javascript and runs in the old MSXSL 2.6. There is a lot of it and I don't have time to rewrite any of it.
I therefore need to run it through MSXSL to process, and am aware that I can probably do something with JNI to get it working, but wondered if anyone else had been in this situation or knows of something that is already done.
I have scoured google, but the only references to it that I have found is people saying not to do it (which I agree with but have no option).


Woody

Current Thread