Questions tagged [tcpdf]

TCPDF is a PHP class created by Nicola Asuni for generating PDF documents without requiring external extensions. TCPDF Supports UTF-8, Unicode, RTL languages, XHTML, Javascript, digital signatures, barcodes and much more. It is a fork of FPDF.

Resources

2193 questions
50
votes
14 answers

How to implement custom fonts in TCPDF

In TCPDF, there are only a few fonts to choose from, to create pdf files. I want to set Tahoma as my pdf font. How can I include Tahoma in TCPDF??
Alfred
  • 21,058
  • 61
  • 167
  • 249
43
votes
8 answers

TCPDF output without saving file

How to use TCPDF to output pdf file in browser without saving like in ezpdf?
Mirgorod
  • 31,413
  • 18
  • 51
  • 63
43
votes
9 answers

Manual Page Break in TCPDF

I am using TCPDF to generate the PDF in one of my projects. I simply create a HTML file and give it to the TCPDF to handle the PDF generation. But now I have some HTML where multiple certificates are added one after the other and I want to have a…
swapnilsarwe
  • 1,290
  • 1
  • 8
  • 13
42
votes
10 answers

TCPDF not render all CSS properties

I try to make a PDF writing CSS and HTML but my CSS doesn't appear in my PDF. The only thing considered is the font-size and font-color. I give you the code (sorry, it's a little long...) $config =…
Elorfin
  • 2,487
  • 1
  • 27
  • 50
41
votes
12 answers

TCPDF Save file to folder?

I'm using TCPDF to print a receipt and then send it to customer with phpMailer, but I have a problem: I have no idea how to save the file into a pdf. I've tried this: // reset pointer to the last page $pdf->lastPage(); //Close and output PDF…
user1537415
37
votes
6 answers

Changing or eliminating Header & Footer in TCPDF

AddPage() in tcpdf automatically calls Header and Footer. How do I eliminate/override this?
ChuckO
  • 2,543
  • 6
  • 34
  • 41
34
votes
6 answers

PHP TCPDF remove header's bottom border

I am trying to create a header in TCPDF, however it always have a border underneath of it. Is there a way I can remove the bottom border?
Bill
  • 17,872
  • 19
  • 83
  • 131
34
votes
9 answers

TCPDF: HTML table and page breaks

I am creating a large HTML table and I have problem with page breaks as you can see in the following image: Is there a method settle down the problem automatically? Or what is the way to do it?
Koney
  • 341
  • 1
  • 3
  • 3
32
votes
15 answers

TCPDF ERROR: Some data has already been output, can't send PDF file

I keep receiving this error when trying to add my own array into the code. Here is my array; $array = array(); while (odbc_fetch_row($rs)) { $array[] = odbc_result($rs,'Product Name'); } $test = print_r($array); The original code is here.…
Alex
  • 493
  • 1
  • 6
  • 11
31
votes
7 answers

TCPDF Custom page size

This example on tcpdf's website shows how to use page formats like A4, A5 etc, but how do I set tcpdf to use custom sizes like 175mm x 266 mm? Solutions appreciated.
abel
  • 2,377
  • 9
  • 39
  • 62
29
votes
4 answers

tcpdf - start with existing PDF document

I have several PDF templates that I would like to load and modify and output using tcpdf. Is it possible to load an existing PDF and use it as a starting point in tcpdf?
Marko
  • 3,499
  • 3
  • 24
  • 22
27
votes
16 answers

TCPDF UTF-8 symbols not showing up

Im using latest TCPDF version(5.9). But have some strange problems with encoding. I need Lithuanian language symbols like: ąčęėįšųūž. But get only few of it. Other remain like ????? So what should I do ? I use default times font(it comes with TCPDF…
Bounce
  • 2,066
  • 6
  • 34
  • 65
25
votes
13 answers

TCPDF ERROR: [Image] Unable to get image

I'm using TCPDF with Drupal's print module to generate PDF of articles, & ending up with following error message when I click the link to generate PDF: TCPDF ERROR: [Image] Unable to get image:…
Shafiul
  • 2,832
  • 9
  • 37
  • 55
25
votes
2 answers

TCPDF set bottom margin zero

I am creating pdf using TCPDF in php,I need to include my data into pdf without bottom margines,The data will be included at the end of the page. $pdf->SetLeftMargin(14); $pdf->SetTopMargin(6); $pdf->SetFont($fontname, '',…
Shijin TR
  • 7,516
  • 10
  • 55
  • 122
21
votes
5 answers

Why does TCPDF ignore my inline CSS?

I am trying to create a PDF file using TCPDF. But When I tried to insert inline CSS into the HTML, it's displaying a blank page! Here are a few lines of my HTML: pdf->AddPage(); // set font $pdf->SetFont('helvetica', 'B', 20); $pdf->Write(0,…
AssamGuy
  • 1,571
  • 10
  • 30
  • 43
1
2 3
99 100