Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Lara Pdf Merger

Lara Pdf Merger Laravel Package

daltcore/lara-pdf-merger

Laravel package for merging multiple PDF files into a single document. Offers a simple API to combine PDFs, reorder or select pages, and output the merged file, making PDF assembly easy within Laravel applications.

View on GitHub
Deep Wiki
Context7

At a glance

Frequently asked questions about Lara Pdf Merger
How do I install daltcore/lara-pdf-merger in a Laravel application?
Install it with composer require daltcore/lara-pdf-merger. On the supported stack, Laravel 7 and PHP 7.4, Composer should resolve the package and Laravel auto-discovery registers the service provider and facade. On modern Laravel or PHP 8.1+ installations Composer will likely refuse the constraints, so you must fork the package, widen composer.json, and install it through a VCS or path repository.
Does daltcore/lara-pdf-merger support Laravel 10, 11, or 12 and PHP 8.1+?
No. The stated support matrix is Laravel 7.0 and PHP 7.4, with the last release dated 2020-05-06. Laravel 8 and 9 may be usable with constraint widening and runtime validation, but Laravel 10 and newer plus PHP 8.1+ require a fork and deprecation fixes. Treat any modern target as an owned fork, not an out-of-the-box install.
How can I merge PDFs stored in Laravel storage or uploaded files with this package?
The merger works on file paths, so resolve Laravel storage or upload locations to absolute paths, for example with Storage::path() or by moving the upload to a temporary file. Pass the resulting paths to the package's merge API and write the returned merged PDF to disk or stream it as a download response. Validate each input exists and is a readable PDF before merging, because failures can be silent.
Is daltcore/lara-pdf-merger still maintained, and is the repository archived?
The repository is archived and the last release was in May 2020, with single-maintainer provenance and low star count. There is no upstream security patching, PHP minor-version support, or CVE response. If you adopt it, your fork becomes the effective upstream and you own maintenance indefinitely.
How do I register the PDFMerger facade and service provider in Laravel?
On Laravel 7 the package is expected to be auto-discovered, so the service provider and facade alias should register without editing config/app.php. If auto-discovery is disabled, add the provider to the providers array and the facade to the aliases array manually. Watch for alias collisions in applications that already define a PDF or PDFMerger facade, and rename the alias if needed.
Can daltcore/lara-pdf-merger reorder or select specific pages when merging PDFs?
The package is primarily a thin wrapper for concatenating PDFs, and the overview mentions reordering or selecting pages as part of its API. In practice, page-level operations are performed by the underlying FPDI/TCPDF-class engine, so any advanced selection or ordering behavior depends on that transitive library. If you need stamping, watermarking, encryption, or complex page manipulation, expect the abstraction to leak and plan to work with the engine directly.
What are the production risks of using an unmaintained PDF merge package in Laravel?
The main risk is abandonment: no security patches, no PHP compatibility fixes, and a pinned transitive PDF parsing tree that you must audit yourself. PDF parsers process untrusted input and are a meaningful attack surface, so any user-supplied PDFs raise the stakes considerably. Encrypted files, malformed PDFs, AcroForms, bookmarks, and mixed page geometries often degrade silently rather than throwing clear errors. Audit the full resolved dependency tree and confirm licensing, since some PDF libraries carry LGPL obligations.
What alternatives should I consider instead of daltcore/lara-pdf-merger?
If you only need concatenation on Laravel 7 and PHP 7.4, a small maintained wrapper or a direct FPDI/TCPDF integration may be simpler than adopting an archived package. For modern Laravel and PHP 8.2+, prefer a maintained Composer package or call an external tool such as Ghostscript or qpdf from a queued job. If your requirements include stamping, reordering, encryption, or optimization, evaluate build-versus-buy against an external PDF service rather than embedding an old parser.
How should I test PDF merging with daltcore/lara-pdf-merger in Laravel?
Write a feature test that uses Storage::fake() or fixture PDFs, calls your merge endpoint or service, and asserts the response is a valid PDF with the expected page count. Verify page count and basic metadata with a PDF parser rather than only checking the content type, because the package can produce output that opens but drops bookmarks or form fields. Add cases for malformed, encrypted, and mixed-geometry inputs to catch silent degradation. Run the suite on the exact PHP and Laravel versions you will deploy.
Does daltcore/lara-pdf-merger handle encrypted, password-protected, or malformed PDFs?
Do not assume robust handling. The package delegates parsing to its underlying PDF engine, and encrypted, password-protected, malformed, or AcroForm-heavy inputs commonly fail or degrade silently instead of raising clear exceptions. Validate and, where possible, normalize inputs before merging, and add explicit tests for the file types your application accepts. If untrusted PDFs are part of the workflow, treat this as a hard stop pending a dependency and security review.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
jinas/dhivatar
store-doc/laravel-storage-driver
plus-it/laravel-translation-manager
diephp/perhaps
diephp/telegraph
osmaviation/spreadsheet
microsoft/fluentui-system-icons
mmccook/php-json-canonicalization-scheme
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
cgv/localized-resource