This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: xml to pdf or word


On Wednesday 24 October 2001 15:43, Adam Darwin wrote:
> How would one use this FOP processor in ASP?

You wouldn't ;-)

Seriously, I think interfacing FOP with ASP at the API level (i.e. with java 
method calls) could be an integration nightmare with various JVM and class 
libraries problems.

I would suggest calling FOP using HTTP requests, which FOP would in turn 
relay to your ASP data-generating page.

Cocoon (http://xml.apache.org/cocoon2) could be used to provide the "glue" to 
make this work.

Here's the scenario:

a) client makes an HTTP request to Cocoon on a specific path
b) on this path a Cocoon "pipeline" is configured to:
b1) get XML data from your ASP page using HTTP
b2) possibly use an XSLT transform to generate an XSL-FO document
b3) use FOP to generate a PDF document
c) client receives the PDF document from Cocoon as a response to its original 
request.

In this way, your ASP page stays in use as a pure XML generator, and the 
XML-to-PDF conversion is nicely modularized using Cocoon as the "XML-to-PDF 
filter".

To get this working you would need to know:
-How to install Cocoon and configure a pipeline
-How to have Cocoon make HTTP requests to "back-end" servers
-XSL-FO vocabulary
-XSLT to transform your XML

Looks like a lot but this knowledge is reusable for a lot of different 
purposes.

Hope this helps.
-- 
 -- Bertrand Delacrétaz, www.codeconsult.ch
 -- web technologies consultant - OO, Java, XML, C++






 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]