Convert .fdf to .pdf


Posted on 16th Feb 2014 07:03 pm by admin

I currently have a web form that uploads the form data to an .fdf file and emails it.

However, I just realized that most people I email it to cannot open an .fdf and it needs to be in pdf.

Did you know?Explore Trending and Topic pages for more stories like this.
Is there any way to convert an fdf file to pdf using php??


Here is my code which currently creates the .fdf:Code: function createFDF($file,$info){
$data="%FDF-1.2n%âãÏÓn1 0 objn<< n/FDF << /Fields [ ";
foreach($info as $field => $val){
if(is_array($val)){
$data.='<</T('.$field.')/V[';
foreach($val as $opt)
$data.='('.trim($opt).')';
$data.=']>>';
}else{
$data.='<</T('.$field.')/V('.trim($val).')>>';
}
}
$data.="] n/F (".$file.") /ID [ <".md5(time()).">n] >>".
" n>> nendobjntrailern".
"<<n/Root 1 0 R nn>>n%%EOFn";
return $data;
}
No comments posted yet

Your Answer:

Login to answer
172 Like 44 Dislike
Previous forums Next forums
Other forums

Finding digits in variable containing text, and IDing them
$romanstock = "http://www.remoteprice.com/data.asp?storeid=123&itemcode=456&typ

My XSRF Prevention code isn't working
First of all, thanks for the generous help you guys have given me in the past on this forum.
Seco

How to change www in url with a specified name
Hi
I'm trying to change the url http://www.sitename.com/apparels to something like below
http:

Question about the upload of large files
Hi there,

I have a question about the upload of large files, like videos (files generally abo

Guixt issue
Hello all,

We are experiencing the following problem with Guixt:

Some transact

gmmktime or mktime
I live in the UK, i am within the GMT (with daylight saving time ie 1 hour difrence between summer a

update 2 columns by doing inner 2-column query
Hi,
is something like this possible?

update contract_all set col1,col2 =
(

Hyperlink is adding an extra gap to variable
Hi, here's my problem..

I have a php generated page with a hyperlink which opens in a new win

Amend code to allow multiple attachments
Hi

I have a php page that allows the user to browse to a file (image) then sumbit, the confi

php file erros / need help please
Hello

Someone decoded a zend file for me.. after uploaded it on ftp i get some errors, i trye

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash