By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,045 Members | 1,305 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,045 IT Pros & Developers. It's quick & easy.

PHP and Adobe FDF/PDF

P: n/a
I am trying to figure out how to do the following:

1. Upload an Adobe FDF to my server
2. read the field names out of the FDF into MySQL for future use
3. Generate an interview form based upon the fields read
4. write a permanent pdf to the server populating the fields

I can do the upload, I can write to the database and I can generate a
dynamic interview form based upon the fields read. The interaction
with an FDF and PDF are beyond me. Can someone point me in the right
direction to start this?

TIA
Jul 17 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
nc
Matthew Speed wrote:

I am trying to figure out how to do the following:
I am assuming you have the FDF Toolkit installed on
your server and configured properly...
1. Upload an Adobe FDF to my server
2. read the field names out of the FDF into MySQL for future use
OK, let's pretend for simplicity that the FDF transmits
only one field called 'info'. So here's what you do:

$fdf = fdf_open_string($HTTP_FDF_DATA);
$info = mysql_escape_string(fdf_get_value($fdf, 'info'));
fdf_close($fdf);
mysql_query("INSERT INTO sometable SET info='$info'");
3. Generate an interview form based upon the fields read
4. write a permanent pdf to the server populating the fields

I can do the upload, I can write to the database and
I can generate a dynamic interview form based upon the
fields read. The interaction with an FDF and PDF are
beyond me.


For a good reason, for there is none. With FDF, all you
can do is manipulate pre-existing forms. You cannot make
a permanent (i.e., formless) PDF, unless you generate the
PDF from scratch using whatever PDF generation facility
you have (PDFlib, ClibPDF, FPDF, whatever).

Cheers,
NC

Jul 17 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.