PDF合并PHP库:PDF Merge for PHP

jopen 9年前

PDF合并PHP库

Install in composer:

"jurosh/pdf-merge": "dev-master"

Highlights

PDF纵向/横向合并模式

Tested in Laravel4 framework.

使用

// Autoload classses..    // and we can do stuff    $pdf = new \Jurosh\PDFMerge\PDFMerger;    // add as many pdfs as you want    $pdf->addPDF('path/to/source/file.pdf', 'all', 'vertical')    ->addPDF('path/to/source/file1.pdf', 'all')    ->addPDF('path/to/source/file2.pdf', 'all', 'horizontal');    // call merge    $pdf->merge('file', 'path/to/export/dir/file.pdf');

项目主页:http://www.open-open.com/lib/view/home/1416140083977