FPDF: Make custom pdfs from your site
If you want to make a PDF from your web pages for visitors to download, use FPDF, a very simple, powerful PHP class that is free to download, and easy to configure. There are several tutorials on the FPDF website on how to use the class, and the manual makes all the functions easy to use and modify. FPDF makes controlling every aspect of your PDF creation simple, including adding an image or logo, margin, auto-pagination, printing, preview, font, embedded links, and tons of other options. It takes less than an hour to setup and begin using it, which isn't too shabby for all the options you can set. All you need to use it is a fairly recent release of PHP on a web server. The test template that comes with the package is easy to modify for whatever uses you may need, without having to learn what each function does. If the code doesn't already exist in the file you download, FPDF.org has all kinds of examples and code references, some written by the fpdf community that you can cut and paste to wire up whatever you (or a client) may require. FPDF is great for pulling dynamic content from a database since it contains a simplistic HTML parser by default. Feed FPDF one HTML string (from a database, or static HTML) and it will polish off your PDF for you in grand style. For even more fun, you can setup fpdf to receive variables from a GET or POST form then insert them in the script to be displayed in your pdf as well. FPDF is powerful, fast, flexible, and very nearly fun. Not bad for FREE.












