000000000014.png

About

The UPC Barcode Field module defines a UPC barcode CCK field in Drupal. The module is capable of turning a 12 digit UPC string into a PNG barcode image that can be printed out and scanned by a capable barcode reader.

This module has been developed for a specific use-case for the uCount module, but it has been designed with the goal of being independent of that system.

Where to obtain the einbarcode.py script

A copy of the necessary einbarcode.py script can be obtained here: http://einbarcode.danenet.org

How to install and use

Please see the README.txt and INSTALL.txt file for further instructions.

How to make PHP aware of the location of python

The UPC Barcode Field module uses the PHP exec() function to call the 'python' command on the server. Sometimes, depending on your server's distribution, the python command is located in a directory that is not inside the PHP user's path variable. This can be solved by placing the following code at the end of your settings.php file:

(Assume that the python command is located in '/usr/local/bin'):

<?php
$path
= getenv('PATH');
$new_path = '/usr/local/bin'; // Or the location of the python interpreter
putenv("PATH=$new_path:$path");
?>

Windows servers not currently supported

Do to the way the python command is called, Windows web severs are not currently supported. This is a known issue and will be resolved in upcoming versions.

Project Information

Downloads