Download the PHP package igeek/pdfservice without Composer

On this page you can find all versions of the php package igeek/pdfservice. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package pdfservice

iGeek PdfService

A Laravel package for generating PDFs using Gotenberg. Convert Blade views or raw HTML to PDF with support for headers, footers, custom page sizes, and more.

If you do not have Gotenberg set up, you can quickly set it up using Docker. See coolamit/pdfservice to get started.


GitHub Tests Action Status GitHub PHPStan Action Status GitHub Code Style Action Status

License PHP Latest Version on Packagist


The API of this package is inspired by spatie/laravel-pdf (which is an excellent package by Spatie), but does not have a Node.js dependency and uses Gotenberg which is written in Golang.

Minimum Requirements

Installation

Install the package via Composer:

Publish the config file:

Configuration

Add these environment variables to your .env file:

Here the PDFSERVICE_URL is the URL where you can access your Gotenberg server and PDFSERVICE_API_KEY is the API key if you have authentication enabled.

The published config file (config/pdfservice.php):

Usage

Basic Usage with Blade Views

Using Raw HTML

Headers and Footers

Page Formats

Available formats: a0, a1, a2, a3, a4, a5, a6, letter, legal, tabloid

Custom Page Size

Set custom dimensions in inches [width, height]:

Orientation

Margins

Set margins in inches (top, right, bottom, left):

Note: When headers or footers are set and margins aren't explicitly defined, top/bottom margins automatically adjust to 1 inch.

Wait Delay

Control how long Chromium waits before capturing the PDF (useful for JavaScript-heavy content):

Storage Disk

Specify which Laravel filesystem disk to use for saving:

Blade Directives

Use these directives in your PDF Blade views:

Page Number

Page Break

Inline Images

Embed images as base64 from storage paths:

External URLs are passed through as is.

Output Methods

Save to Storage

Download Response

Inline Response

Display PDF in browser:

Get Raw Content

Custom API Credentials

Use different credentials to access Gotenberg API for specific operations:

Fluent Interface

All methods support chaining:

Changelog

Please see CHANGELOG for more information on what has changed recently.

License

This package is released under MIT License (MIT). Please see License for more information.


All versions of pdfservice with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
gotenberg/gotenberg-php Version ^2.15
spatie/laravel-package-tools Version ^1.16
illuminate/contracts Version ^11.0||^12.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package igeek/pdfservice contains the following files

Loading the files please wait ...