PHP wrapper for ZBar library. Allows you to scan barcodes from your PHP project.
- PHP 7.2.0 or newer
- ZBar must be installed in your system
- Program execution Functions must be allowed in your PHP configuration
allow_url_fopen
must be set toOn
if you want to decode barcodes from remote sources
You can install this package via Composer:
composer require catzilla/zbar-wrapper
Very basic example:
<?php
$zbar = new ZBarWrapper();
echo $zbar->decodeSingle('barcode.png'); // returns barcode value
For more options and detailed usage examples see example/example.php