jdtoronto has asked for the wisdom of the Perl Monks concerning the following question:

Esteemed Monks,

I have a need to take a PDF file which already exists and to customise it by adding a 'last page' to it. In the past I have used PDF::API2 to generate PDF's on the fly. But I feel it might be overkill for what I need to do now.

Do you have any suggestions or opinions about the myriad of other PDF modules on CPAN? What would you deem appropriate for a simple, repetitive task like this?

jdtoronto

Replies are listed 'Best First'.
Re: Create and modify PDF files
by dragonchild (Archbishop) on Aug 11, 2004 at 17:53 UTC
    PDF::Reuse looks to be designed for this task.

    ------
    We are the carpenters and bricklayers of the Information Age.

    Then there are Damian modules.... *sigh* ... that's not about being less-lazy -- that's about being on some really good drugs -- you know, there is no spoon. - flyingmoose

    I shouldn't have to say this, but any code, unless otherwise stated, is untested

Re: Create and modify PDF files
by grantm (Parson) on Aug 12, 2004 at 01:40 UTC

    I have successfully used PDF::Reuse to assemble multipage PDFs from single page PDF templates with extra text and lines added on the fly. A colleague has used it for creating huge PDFs from scratch with lots of text, simple graphics and even barcodes. As well as being easy to use it's very fast. The author was very helpful too.