Re: Re: Does anyone here use TCPDF? [SOLVED]
| From: | Dave M G | Date: | Thu, 05 Nov 2009 12:48:07 +0000 |
| Subject: | Re: Re: Does anyone here use TCPDF? [SOLVED] | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-299639@lists.php.net to get a copy of this message | ||
PHP Users,
Finally got a working solution by using TCPDF and FPDI:
require_once('tcpdf.php');
require_once('fpdi.php');
$pdf = new FPDI();
$pdf->AddPage();
$pdf->setSourceFile('template.pdf');
$tplIdx = $pdf->importPage(1);
$pdf->useTemplate($tplIdx);
$pdf->SetFont('kozminproregular', '', 10);
$pdf->SetXY(45, 190);
$pdf->Write(0, "$BF|K\8l(B");
$pdf->Output("sample.pdf", "D");
Hope that helps others.
--
Dave M G