I am doing some testing with FPDF and running into an issue. When setting a container to pull it’s colour from a pre-defined variable it is not honoring the value and I can’t see why not. Example …
Tag: fpdf
Why FPDF’s useImportedPage doesn’t work for PHP code
I receive the following error when using useImportedPage() for generating labels… ErrorException [ Fatal Error ]: Call to undefined method FPDI::useImportedPage(). But when I comment out $pdf-&…
How to generate a pdf on post saving or updating
I’m trying to create a PDF from post content, including some ACF fields. Currently I’ve got it working on a POST form and dynamically creating a PDF each time, but I’d like to make it generate the PDF …
ReturnDatesAsStrings=>true returns timestamp with decimal & zeros
I’m using PHP 7.2, MS SQL Server, fpdf, and phpSpreadsheet to create PDF and Excel reports of my data. Initially I had trouble returning the timestamp (date) fields in the reports, but adding “ReturnDatesAsStrings”=>true in my connection.php solved that problem. The issue now is that the date fields on the reports have a decimal and zeros added and show up
FPDF – Inline bold text
I am trying to create a PDF from PHP and for legal reason we need to make part of our disclaimer BOLD and the disclaimer needs to be outlined. My current code uses: if(isset($_POST[‘optout’]) &&…
add existing pdfs to fpdf
Is there any function that I could call in order to include an existing pdf in my fpdf file? For example $pdf->AddPage(from file example.pdf); something like that? is it posible?
Email PDF Attachment with PHP Using FPDF
I want to email a PDF as an attachment that was created using FPDF. My code looks like this, but the attachment never comes through. Anyone familiar with doing this? I’m hoping to use the PHP mail() function. Answer This ended up working for me: