Download the PHP package isahaq/barcode-qrcode-generator without Composer
On this page you can find all versions of the php package isahaq/barcode-qrcode-generator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package barcode-qrcode-generator
# Barcode & QR Code Generator for Laravel and PHP
A comprehensive barcode and QR code generator package for Laravel and PHP applications. This package provides easy-to-use functionality for generating various types of barcodes and QR codes using TCPDF library.
Features
- Multiple Barcode Types: Support for 30+ barcode types including Code 128, Code 39, EAN-13, UPC-A, and more
- QR Code Generation: Generate QR codes with customizable options using Endroid QR Code
- Multiple Output Formats: PNG, SVG, HTML, JPG, and PDF using TCPDF
- Laravel Integration: Service provider, facades, and Blade directives
- Customizable Options: Colors, sizes, margins, error correction levels
- Comprehensive Testing: Full test coverage with PHPUnit
- Easy to Use: Simple API for both Laravel and standalone PHP usage
- No External Dependencies: Uses only TCPDF and Endroid QR Code libraries
Installation
Via Composer
For Laravel Applications
The package will automatically register the service provider. If you're using Laravel 5.5+, the package will be auto-discovered.
For older Laravel versions, add the service provider to your config/app.php
:
Publish the configuration file:
Usage
Laravel Usage
Using Facades
Using Dependency Injection
Using Blade Directives
Standalone PHP Usage
Configuration
The package configuration file (config/barcode-qrcode.php
) allows you to customize default settings:
Barcode Types
The package supports the following barcode types (using TCPDF):
- C39 - Code 39
- C39+ - Code 39+
- C39E - Code 39 Extended
- C39E+ - Code 39 Extended+
- C93 - Code 93
- S25 - Standard 2 of 5
- S25+ - Standard 2 of 5+
- I25 - Interleaved 2 of 5
- I25+ - Interleaved 2 of 5+
- C128 - Code 128
- C128A - Code 128 A
- C128B - Code 128 B
- C128C - Code 128 C
- EAN2 - EAN 2
- EAN5 - EAN 5
- EAN8 - EAN 8
- EAN13 - EAN 13
- UPCA - UPC-A
- UPCE - UPC-E
- MSI - MSI
- MSI+ - MSI+
- POSTNET - POSTNET
- PLANET - PLANET
- RMS4CC - RMS4CC
- KIX - KIX
- IMB - IMB
- CODABAR - Codabar
- CODE11 - Code 11
- PHARMA - Pharma Code
- PHARMA2T - Pharma Code Two-Track
QR Code Options
QR codes support the following options (using Endroid QR Code):
- size: Size of the QR code (default: 300)
- margin: Margin around the QR code (default: 10)
- foreground_color: Foreground color as RGB array (default: [0, 0, 0])
- background_color: Background color as RGB array (default: [255, 255, 255])
- error_correction_level: Error correction level (low, medium, high, quartile)
- round_block_size_mode: Round block size mode (margin, enlarge, shrink)
- logo_path: Path to logo image to embed in QR code
- logo_size: Size of the logo (default: 100)
Advanced Usage
Custom Options
Multiple Formats
Validation
Testing
Run the test suite:
Or with PHPUnit directly:
Examples
E-commerce Product Barcode
Contact QR Code
URL QR Code with Logo
Dependencies
- TCPDF: For barcode generation in multiple formats
- Endroid QR Code: For QR code generation with advanced features
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Run the test suite
- Submit a pull request
License
This package is open-sourced software licensed under the MIT license.
Support
For support, please open an issue on GitHub or contact the maintainer.
Changelog
v1.0.0
- Initial release
- Support for 30+ barcode types using TCPDF
- QR code generation with custom options using Endroid QR Code
- Multiple output formats (PNG, SVG, HTML, JPG, PDF)
- Laravel integration with service provider and facades
- Blade directives
- Comprehensive test suite
- No external barcode library dependencies