mawo/barcode

Create 2D data matrix

Maintainers

Package info

github.com/mawo/barcode

pkg:composer/mawo/barcode

Statistics

Installs: 121

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 1

dev-master / 1.0.x-dev 2020-05-11 19:52 UTC

This package is auto-updated.

Last update: 2026-03-12 09:15:01 UTC


README

Generate GS1 compatible Data Matrix with multiple code blocks divided by fnc1.

The only supported function is "getSvg()"

If you don't need multiple data blocks and want more features (e.g. other output formats) have a look at https://github.com/kreativekorp/barcode

Example:

$options=[
    'gs1' => true,
    'fnc1char' => '~',
    'rect' => false,
];
$bc = new Mawo\Barcode\Encoder\DataMatrixEncoder;
$data = '~1234567890123456789012~ABC123DEFGHIJKLMNOP456789QRSTUVWXY~1234567890';
echo $bc->getSvg($data, $options);