tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Peter Thomsen" <p...@mail1.stofanet.dk>
Subject SV: [tcusers]Re: JSP to PDF
Date Tue, 08 Jan 2002 01:32:16 GMT
I Found this link at www.servlets.com it may be what you are looking for if
you do not want to use FOP.

<Snip from servlets.com>
A library for generating PDF files from a servlet. Useful if you want to
control exactly how your servlet's output will look. It requires JDK 1.2.

http://www.lowagie.com/iText/
</Snip>

Look at it and see if it is something you can use.

Peter Thomsen
-----Oprindelig meddelelse-----
Fra: Darth Darknerd [mailto:darknerd@realmspace.com]
Sendt: 7. januar 2002 23:54
Til: Tomcat Users List
Emne: Re: [tcusers]Re: JSP to PDF


I plead ignorance about JSP, but doesn't JSP make HTML pages, not XML
pages?!?

You create your data content in XML.  Then create a separate document
style sheet
using FO (Formatting Objects) markup.  These two documents will be then
converted
into a PDF file using FOP.  FOP is one implementation of the FO
specification.
Other programs can convert the same FO style sheet document into other
formats
like Java AWT for example.

The Java servlet can be used to auto-generate the XML.  Thus the data
placed
into the XML document can be extracted from other sources, like database
servers through JDBC driver, CORBA servers (jacORB), messaging servers
(JBOSS),
etc.

On a last note, you can optionally create a style sheet for HTML as well.
Thus
you can use two style sheets, one for FO markup for things like PDF, SVG,
AWT, etc.,
and one for HTML.

The possibilities are limitless with XML....


On Friday, November 9, 2001, at 09:15  AM, Tim McLaughlin wrote:

> On 11/08/2001 23:07, "Lars Nielsen Lind" <moonie@worldonline.dk> wrote:
>
>> Is it not possible to create a PDF-file from JSP?
>>
>> I believe I have heard something about FOP - you can get it from the
>> Apache /
>> Jakarta website.
>>
>> /Lars Nielsen Lind
>
>
> I don't know about using it from JSP, but I have a colleague who has used
> FOP, and he loved it.  You basically have an XML document that describes
> the
> layout using FOP tags, then it is processed and a PDF is produced.
>
> You could use the JSP to gather the information, but then I imagine you'd
> want a servlet to handle it and process the FOP document, and then forward
> to another JSP that offered a link to the resulting PDF.  Just my take on
> it.
>
> I seem to recall that there was some commercial package involved in what
> he
> was doing, but that may have been before the Jakarta project.  I don't
> know
> for sure.
>
> Tim
>
> --
> Tim McLaughlin
> tim@macwebb.com
>
>
>
> --
> To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
> Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>
>


--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>



--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>


Mime
View raw message