No issues here; I'm using this package to generate SVG barcodes which will show up in a PDF document (via barryvdh/laravel-snappy):
{!! DNS1D::getBarcodeSVG($foo->bar, "C39", 1, 25, '#2A3239') !!}
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I tried to generate barcode using milon/barcode package, but every first time i generate it shows me blank barcode. Anyone facing same issue as well?
echo '<img src="data:image/png;base64,' . DNS1D::getBarcodePNG("4", "C128B") . '" alt="barcode" />';
I just tested it and inserted {!! DNS1D::getBarcodeSVG('123', "C39", 1, 25, '#2A3239') !!} in a blade file and it showed up correctly the first time. Even printing the page via ctrl+p works. Also echo '<img src="data:image/png;base64,' . DNS1D::getBarcodePNG("4", "C128B") . '" alt="barcode" />'; worked...
Does it make a difference if you change the browser?
Please or to participate in this conversation.