https://github.com/rawilk/laravel-printing
Direct printing for Laravel apps.
https://github.com/rawilk/laravel-printing
cups ipp laravel-printing printer printnode
Last synced: 5 months ago
JSON representation
Direct printing for Laravel apps.
- Host: GitHub
- URL: https://github.com/rawilk/laravel-printing
- Owner: rawilk
- License: mit
- Created: 2020-06-26T14:44:58.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-03-31T18:32:54.000Z (6 months ago)
- Last Synced: 2025-04-04T06:00:28.866Z (6 months ago)
- Topics: cups, ipp, laravel-printing, printer, printnode
- Language: PHP
- Homepage: https://randallwilk.dev/docs/laravel-printing
- Size: 593 KB
- Stars: 495
- Watchers: 11
- Forks: 77
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: .github/CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
- Security: .github/SECURITY.md
Awesome Lists containing this project
README
# Printing for Laravel
[](https://packagist.org/packages/rawilk/laravel-printing)

[](https://packagist.org/packages/rawilk/laravel-printing)
[](https://packagist.org/packages/rawilk/laravel-printing)
[](https://github.com/rawilk/laravel-printing/blob/main/LICENSE.md)
Printing for Laravel allows your application to directly send PDF documents or raw text directly from a remote server
to a printer on your local network. Receipts can also be printed by first generating the raw text via the `Rawilk\Printing\Receipts\ReceiptPrinter` class, and then sending the text as a raw print job via the `Printing` facade.```php
$printJob = Printing::newPrintTask()
->printer($printerId)
->file('path_to_file.pdf')
->send();$printJob->id(); // the id number returned from the print server
```Supported Print Drivers:
- PrintNode: https://printnode.com
- CUPS: https://cups.org
- Custom: Configure your own custom driver## Documentation:
For documentation, please visit: https://randallwilk.dev/docs/laravel-printing
## Installation
You can install the package via composer:
```bash
composer require rawilk/laravel-printing
```You can publish the config file with:
```bash
php artisan vendor:publish --tag="printing-config"
```The contents of the default configuration file can be found here: https://github.com/rawilk/laravel-printing/blob/main/config/printing.php
## Testing
```bash
composer test
```## Changelog
Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.
## Contributing
Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.
## Security
If you discover any security related issues, please email randall@randallwilk.dev instead of using the issue tracker.
## Credits
- [Randall Wilk](https://github.com/rawilk)
- [All Contributors](../../contributors)
- _Mike42_ for the [PHP ESC/POS Print Driver](https://github.com/mike42/escpos-php) libraryInspiration for the PrintNode API wrapper comes from:
- [PrintNode/PrintNode-PHP](https://github.com/PrintNode/PrintNode-PHP)
- [phatkoala/printnode](https://github.com/PhatKoala/PrintNode)Inspiration for certain aspects of the API implementations comes from:
- [stripe-php](https://github.com/stripe/stripe-php)
## Disclaimer
This package is not affiliated with, maintained, authorized, endorsed or sponsored by Laravel or any of its affiliates.
## License
The MIT License (MIT). Please see [License File](LICENSE.md) for more information.