Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Created: Barcode PNG then to PDF Label

2009-03-23
2013-05-30
  • Hi,
    I wanted a good label for our School Library here. So I am working on a Barcode Labeling script. Since I am not one of the projects members, I wanted to offer the code up.

    However, it needs some testing, and it sits outside of OpenBiblio, meaning my code uses a htdocs/<files> and htdocs/openbiblio hard coded scheme at the moment.

    I am unable to provide the file here, I will be more then happy to email it to anyone who requests it.

    Here is what it does currently...
    Will search for every copy of book, fetch the title, barcode, and 3 call number fields. It will then create "png" files in a folder called barcodes, then it will go through and generate Avery 5160 format labels in a PDF using those image.

    Images are named barcodenmbr.png I.E. 60646.png, if the file exists it will not make a new one.

    The script currently uses the GD library, FPDF, and a modified PDF_Labels.php file from the FPDF website.

    Because I have not set limits, or anything yet (this is a test script), it will likely have a fatal memory error with large book databases.

    It needs to sit in the structure like this currently if you can not match this, the script is useless:
    webroot [htdocs / www / apache]
    |
    |-barcode.php
    |-[barcodes]
    |-fpdf.php
    |-[openbiblio]
    |-PDF_Label.php

    If you would like to try it out, let me know. <span style="font-weight:bold">I can provide no warranty, it is solely for testing</span>, and I will try and make improvements based on its usage.
    Current Barcode format is 3of9, GD Barcode can use other, and I will try and make that an option.

    Email me for the zip file (it includes barcode.php, fpdf.php, barcodes folder [empty],and the modified PDF_Label.php) ssammons  a t npelem.com

    Thanks!

     
    • Hi. I am currently working on a church library using openbiblio and I am interested to test your code. my email is halbrook@nazarene.org.ph

      Thanks.