From: "J.Pietschmann" <[EMAIL PROTECTED]>

Chris Bowditch wrote:
but you can implement it yourself very easily with a small java program.

Well, that's an exaggeration. Extracting the style sheet while maintaining important details of the surrounding XML can easily become a real headache. Big XML docs are another problem because you'll essentially have to build a DOM. Take a look at Saxon's code for this purpose (and the associated bugs and history). (Note: Saxon is GPL)


I dont agree. Write a class that extends DefaultHandler and implement the processingInstruction method. Parse the XML file using SAX, get the path to the stylesheet from the data value passed to the processInstruction method, throw an exception to halt the SAX parser. Then pass the path of both XML file and XSL file to FOP's XSLTInputHandler class. Job done.


I can supply my 20-line class if anyone is interested.

Chris

_________________________________________________________________
Express yourself with cool emoticons - download MSN Messenger today! http://www.msn.co.uk/messenger



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to