tags:

views:

416

answers:

5

How can I make a PDF file in PHP. What I want to make is a student list. So I want to query the database, get the information and give it to the user as a PDF when he clicks generate student list.

+1  A: 

PEAR has the PEAR::File_PDF package.

Kevin Loney
+1  A: 

There are are already many libraries available with PHP bindings. One that comes to mind is PDFLib (www.pdflib.com). If I am not mistaken there should even be a lite version that you can use for free. But just check it out.

Hope it helps

+9  A: 

You have two good options first is the standard php library for manipulating pdf's: http://us2.php.net/pdf

Or you can use http://www.fpdf.org/. I would recommend the second.

Other options include: www.pdflib.com

jtyost2
Another recommendation for fpdf. Had performed well for us, even under heavy loads.
Mainegreen
Fpdf works really well. +1
Patjoh
+1  A: 

I use the ezPDF class. Lightweight, simple, easy to use, and handles most cases.

mabwi
A: 

FPDF is a classical in the field. It seems it has limitations when handling Unicode (eg. Asian char sets), so there are libraries extending it (UFPDF, TCPDF...).

PhiLho