PDFMerge based on TCPDI and TCPDF. Supports PDFs up to v1.7.
The recommended way to install PDFMerge is via Composer
composer require zaslat/pdf-merge
PDFMerge requires PHP version > 8.0
use Zaslat\PDFMerge;
$pdfMerge = new PDFMerge();
$pdfMerge->addFile('file01.pdf');
$pdfMerge->addFile('file02.pdf');
$pdfMerge->merge(PDFMerge::OUTPUT_BROWSER, 'merged.pdf');