Add sub-headers in all pages with FPDF
问题 I have a simple script that generates a PDF file. I'm getting the info I need from the database and using a foreach to create the pages of the PDF file, and the last page I have some charts and other info that are not retrived from DB. All the pages, except this last one, must have a subheader. My current code is: foreach ($sql as $key => $value) { $pdf->Cell(20, $line_height, $value['sale_id'], '', '', 'L'); $pdf->Cell(90, $line_height, $value['product'], '', '', 'L'); $pdf->Cell(90, $line