pdf programming visually

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

Post Reply
User avatar
yacahuma
Forum Regular
Posts: 870
Joined: Sun Jul 01, 2007 7:11 am

pdf programming visually

Post by yacahuma »

Does anyone knows of a product where I can draw a pdf, the same way you write a word document,

assign fields to it, and have the stubs generated to interface with it???
alex.barylski
DevNet Evangelist
Posts: 6267
Joined: Tue Dec 21, 2004 5:00 pm
Location: Winnipeg

Re: pdf programming visually

Post by alex.barylski »

You can generate a PDF in any creator....use Word and convert it using Foxit PDF creator (print driver).

Use placeholders, like:

%%FIRST_NAME%%

Inside the document and str_replace them on the fly. Make sure you are not encrypting the PDF though otherwise your str_replace will not work.

Alternatively, you oculd use a PDF library to dynamically construct PDF document using "blocks" and send out a completed PDF that way.

Maybe you could use: http://www.fpdf.org/

I am not clear on what you are trying to do though...

Cheers,
Alex
User avatar
yacahuma
Forum Regular
Posts: 870
Joined: Sun Jul 01, 2007 7:11 am

Re: pdf programming visually

Post by yacahuma »

Well,

I finally found the answer . And like many times, it turns out to be a simple one.

Use Adobe Acrobat professional and create fields for the form. You can draw them on top of the existing pdf. Then using a little library
http://koivi.com/fill-pdf-form-fields/tutorial.php
you can search and replace for the fields you just created.

some info about fdf
http://www.citationsoftware.com/faqFDF.htm

Basically, the data is in one place and the form is in another.

I found another library,

http://www.setasign.de/products/pdf-php-solutions/fpdi/
Post Reply