Uses FPDF 1.7, tested in Symfony 2.5+
Package available on Composer.
If you're using Composer to manage dependencies, you can use
$ composer require "royopa/fpdf-symfony2": "dev-master"
Or
You can include the following in your composer.json file:
{
"require": {
"royopa/fpdf-symfony2": "dev-master"
}
}
And those to app/autoload.php
:
$classMap = array(
'Fpdf_' => __DIR__.'/../vendor/royopa/fpdf-symfony2/lib/FPDF/FPDF.php',
'Fpdi_' => __DIR__.'/../vendor/royopa/fpdf-symfony2/lib/FPDF/FPDI.php'
);
$loader->addClassMap($classMap);
$pdf = new \FPDF_FPDF();
$pdi = new \FPDF_FPDI();
FPDF is a PHP class which allows to generate PDF files with pure PHP, that is to say without using the PDFlib library. FPDF is a open source project: you may use it for any kind of usage and modify it to suit your needs.
On the fpdf homepage you will find links to the documentation, forums and so on.