Open aadamsx opened 9 years ago
+1
@lvarayut, just use PDFtk server (command line)... it will allow for form fills.
You'll need to build a FDF or XFDF file to populate the PDF, but you can use xmlbuilder for that (can use JSON too).
@aadamsx Thanks for your information. I will try it soon.
Currently this feature is missing in PDFkit, the underlying PDF engine. So it's probably not going to be done soon.
@aadamsx I just built something using pdftk and it works well, but it'd be nice if we could do this client-side! Thanks @jthoenes for the link
you'd have to have some sort of processor (which is what pdftk is) uploaded to the client (the browser). Since your idea is that this would all live in the browser, the processor might have to either be a plug in or written in javascript.
If this was a browser in a older iphone for example, it might be that processing on the server and outputting to the browser might be faster.
I saw somewhere an approximation of the pdftk codebase I think written in php (not sure really). Someone would need to spend some time doing the code conversion to javascript.
As far as I know, pdftk is the only real solution for form fills (robust) on unix based systems. I think iText can be used for windows based systems.
+1
@jthoenes , any update on this functionality? @karissa , can you please share how you made it work?
thanks in advance.
I would also love this feature
It's not going to happen in the package. You must use PDFtk.
How did you use PDFtk to generate that kind of a form @aadamsx
Is there a better way to do this? I am 3 years behind, trying to generate this kind of a form using PDFMAKE
I'm looking to generate a pdf from an existing pdf "template". For example, the pdf "template" would have the layout, text, and "fields" -- all that would be left to do is fill in "fields" with data. I guess like a fill Forms scenario...
I would like to populate these fields with the appropriate data from a mongo collection, and generate a new pdf from it.
All the pdf packages I've came across seem to generate pdfs, but none seem to generate a pdf from a template populated with data I provide.
Is this possible with this package?
For example, the following is part of a pdf document, the "fields" need to be populated with data I get from a collection: