Questions tagged [fpdi]

A PHP class which allows to read pages from existing PDF and generate new files based on FPDF.

Home page of FPDI

FPDI is a PHP class based on which allows to generate and manipulate PDF files with pure PHP, that is to say without using the PDFlib library. F from FPDI stands for Free: you may use it for any kind of usage and modify it to suit your needs.

327 questions
44
votes
8 answers

How to edit or write on existing PDF with Ruby?

I have a couple of PDF template files with complex content and several blank regions/areas in them. I need to be able to write text in those blank regions and save the resulting PDFs in a folder. I googled for answers on this question quite…
Alex Kovshovik
  • 4,085
  • 4
  • 35
  • 36
36
votes
9 answers

FPDF error: This document (testcopy.pdf) probably uses a compression technique which is not supported by the free parser shipped with FPDI

I am running the following code and giving me this error : FPDF error: This document (testcopy.pdf) probably uses a compression technique which is not supported by the free parser shipped with FPDI. I used another pdf named test.pdf and that works…
user851939
32
votes
1 answer

How to set encoding in PHP FPDI library

How to set UTF-8 encoding in php library named FPDI? Here's library: https://www.setasign.com/products/fpdi/manual/ The code: $pdf = new Fpdi(); $pdf->AddPage(); $pdf->setSourceFile('PdfDocument.pdf'); $tplIdx = $pdf->importPage(1); …
Adam Kozlowski
  • 5,606
  • 2
  • 32
  • 51
14
votes
3 answers

FPDI merge PDF files, strange line appears

I have to merge PDF files when a user needs to. The files are already existing and everything is fine. I'm using the fallowing code to merge the files: class concat_pdf extends FPDI { var $files = array(); function setFiles($files) { …
Nikoloff
  • 4,050
  • 1
  • 17
  • 19
13
votes
3 answers

Problem with size of the imported PDF template with FPDI+TCPDF

I am stuck in a very complex situation. I am working on a PHP Web apps for Greeting card. For this, I am using some Linux tools and TCPDF and FPDI. Let me tell you how it all works: there is 4 page greeting card template PDF file. this is custom…
Ravish
  • 2,383
  • 4
  • 37
  • 55
13
votes
7 answers

Is there a way to make FPDF/FPDI or Zend_Pdf support the parsing of PDFs greater than 1.4?

I am trying to add an existing PDF (created otherwise) to a PDF created with FPDF using FPDI. It seems to work find for most PDFs, but I get the following error: FPDF error: Unable to find xref table. After some testing, I figured out that if I use…
Darryl Hein
  • 142,451
  • 95
  • 218
  • 261
13
votes
1 answer

PDFMerger with FPDI-PDF-PARSER

FPDI PDF Files merger is being used. However, I ran into the following issue while trying to merge PDF files versions 1.5 and higher. The following was the error I received: This document (doc.pdf) probably uses a compression technique which is …
hello_its_me
  • 743
  • 2
  • 19
  • 52
13
votes
2 answers

Can FPDF/FPDI use a PDF in landscape format as a template?

I am trying to import an existing PDF as a template with FPDI. The template is in landscape format. If I import the template into a new document the template page is inserted in portrait form with the content rotated 90 degrees. If my new…
Jim OHalloran
  • 5,859
  • 2
  • 37
  • 57
11
votes
6 answers

FPDI with Multiple Pages

I am new to PHP and am having a bit of a hard time with using FPDI when it comes to inserting multiple pages. I have a .pdf file which consists of 3 pages. I ended up saving page 1 as a separate page out of the 3 and that worked with my code, but…
hiter202
  • 109
  • 1
  • 2
  • 6
9
votes
2 answers

Preserve internal links using FPDI

I'm trying to dynamically add some text to an existing pdf file. I've tried both FPDF and TCPDF combined with FPDI to import the existing pdf. That's ok. But, as expected, all existing links from the original pdf are gone. Then, I tried to…
9
votes
4 answers

FPDI free parser that supports PDF version higher than 1.4

Is there a free/open-source PDF parser out there that can do the job? The free parser that comes with FPDI only supports PDF version up to 1.4. I tried TCPDF but it didn't work. I know I can change the PDF version of a PDF file thru Acrobat but I…
kevinandrada
  • 449
  • 2
  • 5
  • 14
7
votes
2 answers

Insert images files in existing PDF file using PHP

My need is that I upload two image files and that should be added to an existing PDF file. I have read about FPDF, basing on that I have followed this post link. In case if somebody can post a simple working example/link it would be helpful for…
125369
  • 3,547
  • 20
  • 52
  • 70
7
votes
2 answers

How to get the exact modified PDF using FPDF/FPDI?

i have a task to modify the PDF and add an image into it, for which I Have used the FPDF and FPDI libraries.. whose action code is given below: AddPage(); //Set…
OM The Eternity
  • 15,694
  • 44
  • 120
  • 182
7
votes
4 answers

wrong symbol exported in fpdf... ñ as ñ ..?

I dont know whats the problem but whenever I call the letter ñ from $_POST function it puts it in my fpdf as ñ .. any idea why?
NORM
  • 235
  • 4
  • 7
  • 14
6
votes
3 answers

FPDF Getting "Incorrect output destination" but the error code showing the correct destination

I'm trying to use FPDF and FPDI to edit a PDF and add text to it. I keep getting an "Incorrect output destination" error but the destination is the correct location that I want it to create a file in, why does FPDF not like my output destination?…
movac
  • 1,576
  • 3
  • 21
  • 45
1
2 3
21 22