Web Analytics

Fill the form & Get Installation Support

Any Question or Concerns?
Let's discuss





    Magento 2 print barcode with unique code in invoice pdf

    Related articles

    There are so many third party libraries or extensions that are available for generating/tracking barcodes.

    Today I’m going to share with you that how we can easily add unique barcodes in our pdf using Magento default Zend library.

    First, you have to create [Vendor Name]/[Module Name]/etc/di.xml in your existing module or create a new module and add the below code:

    Then you have to create a plugin file [Vendor Name]\[Module Name]\Plugin\Invoice.php and add the below code:

    After creating both files run php bin/magento cache:flush and see any invoice pdf barcodes are printed as below.

    Contact us for scientific strategies to increase your site conversions





      Connect With Us