pdffillerjs / pdffiller

Take an existing PDF Form and data and PDF Filler will create a new PDF with all given fields populated.
MIT License
289 stars 114 forks source link

Extract PDF form field names from a PDF form #86

Open deshario opened 5 years ago

deshario commented 5 years ago

How to extract pdf form fields from this lib ... Is it possible to extract from using javascript only ?

PDFTK Command : # pdftk input.pdf dump_data_fields

Click here for Sample

vijaypatoliya commented 5 years ago

I am looking for a similar solution. I want to get PDF label name same as in PDF.

jelizarovas commented 3 years ago
var nameRegex = null;  

var FDF_data = pdfFiller.generateFDFTemplate( sourcePDF, nameRegex, function(err, fdfData) {
    if (err) throw err;
    return fdfData;
});

it generates field names from the form. you can try var pdfFiller = require('pdffiller-keepfields'); to also get field values

saiprasad9467 commented 3 years ago

I need fields and its values PDF-EXTRACT PDF-EXTRACT-RESULT

The above is my requirement and the image i pasted will be sent as the pdf

jelizarovas commented 3 years ago

You can't get the values with this library. I switched to "pdf-lib" to have client side pdf manipulation and react-pdf to display that updated data

saiprasad9467 commented 3 years ago

Is it possible in pdf-lib for my data retrieval as mentioned above??

jelizarovas commented 3 years ago

Please explain more in detail what do you mean