I’m using pdftk to fill in a PDF form with an XFDF file. However, for this project I do not know in advance what fields will be present, so I need to analyse the PDF itself to see what fields need to be filled in, present an interface to the user accordingly, and then generate an XFDF file from that to fill in the PDF form.
How do I get the field names? Preferably command-line, .NET or PHP solutions.
I can get my client to export the XFDF file (which contains field names) using Acrobat along with the PDF, which avoids this problem completely.