PHP to generate one of the barcode bar code Introduction

Source: Internet
Author: User
Tags character set control characters


In some manufacturing industries barcodes are essential. For example, print work orders, raw materials out of the warehouse, finished products out of the warehouse, such as the need to scan the barcode . Recently found that the company printed on the list of the bar code, print work orders are written in PHP, and then see how the source code is achieved. The original is a class that generates barcode to transfer the corresponding data to the program and generate a JPG file.



I searched the Internet search for other ways to achieve barcode, find a foreign open source program specifically used to generate "one-dimensional barcode." First, review the relevant knowledge of bar code.



Barcode classification



One, according to the Code system classification



1.UPC yards



Canada also adopted UPC codes in commercial systems after the United States first applied the UPC code to domestic commercial systems in 1973. UPC code is a continuous digital code system with fixed length, whose character set is digital 0~9. It takes four element widths, each of which is 1, 2, 3, or 4 times times the unit element width. There are two types of IPC codes, namely upc-a Code and UPC-E code.



2.EAN yards



In the 1977, EEC countries developed the European article Code EAN in accordance with the UPC code, which was compatible with the UPC code, and both had the same symbolic system. The character numbering structure of EAN code is the same as that of UPC code, and it is also a fixed and continuous digital code system, whose character set is digital 0~9. It takes four element widths, each of which is 1, 2, 3, or 4 times times the unit element width. There are two types of EAN codes, namely EAN-13 Code and EAN-8 code.



3. Cross 25 yards



Cross 25 code is a continuous type of 0~9 digital code system with variable length, whose character set is digital. Takes two element widths, each of which is a wide or narrow element. The number of encoded characters is even, the data in all odd positions is coded, and the data in even position is encoded in null. If an odd number of data is encoded, a bit 0 is made before the data to make the data an even number of digits.



4.39 yards.



The 39 yards is the first alphanumeric code system. 1974 by Intermec Company launched. It is a discrete type of digital alphanumeric code system with comparable length. Its character set is the number 0-9, 26 uppercase letters, and 7 special characters (-、。 , space,/,%, ¥), a total of 43 characters. Each character consists of 9 elements, with 5 bars (2 widths, 3 narrow bars) and 4 empty (1 wide and 3 narrow), which is a discrete code.



5. KUDBA Code



The KUDBA code Bar, which appeared in the 1972, is a continuous, variable-length, digital-coded system of self calibration. Its character set is the number 0-9 and 6 special characters (-,:,/,. , +, ¥), a total of 16 characters. Often used in warehouses, blood banks and air courier packages.



6.128 yards.



128 yards appeared in 1981, is a variable length of the continuous type of digital code system. It uses four element widths, each character is 3 bars and 3 empty, a total of 11 cell element width, also known as (11,3) code. It consists of 106 not, with barcode characters, each barcode character has three meanings different character sets, respectively A, B, C. It uses these 3 alternating character sets to encode 128 ASCII codes.



7.93 yards.



The 93-yard is a continuous alphanumeric code system with variable length. Its character set becomes a number. 0-9, 26 uppercase letters and 7 special characters (-、。 , space,/, +,%, ¥) and 4 control characters. Each character consists of 3 bars and 3 rare, a total of 9 element widths.



8.49 yards.



49 yards is a multiple-line continuous, variable-length alphanumeric code system. Appeared in 1987, mainly used for symbols on the label of small items. Use a variety of element widths. Its character set is the number 0-9, 26 uppercase letters, and 7 special characters (-、。 , space,%,/, +,%, ¥), 3 function keys (F1, Indra, F3), and 3 transform characters, a total of 49 characters.



9. Other code system



In addition to the above code, there are other codes, such as 25 yards appeared in 1977, mainly for electronic components labels; matrix 25 yards is 11 yards of deformation; Nixdorf code has been replaced by EAN code Plessey code appeared in May 1971 mainly for the library.



Two, by the dimension of classification



1. Ordinary one-dimensional barcode



The common one-dimensional barcode has been popularized and widely used since its inception. But because the information capacity of one-dimensional barcode is very small, such as goods on the bar code can only accommodate 13 digits, more information to describe the commodity can only rely on the support of the database, leaving the pre-established database, the bar code has become a source, non-existent, so the application of the bar code has been limited to a certain extent.



2. Two-D barcode



In addition to the advantages of ordinary bar code, two-dimensional bar code also has a large information capacity, high reliability, confidentiality security strong, easy to produce, low cost advantages. <BR> United States symbol Company in 1991 formally launched a two-dimensional barcode named PDF417, referred to as PDF417 barcode, namely "portable data file." FDF417 Barcode is a high density, high information content of portable data files, is the realization of documents and cards, such as large capacity, high reliability information automatic storage, carry and can be automatically read by machines ideal means.



3. Multidimensional Barcode



Since entering the 1980s, people around how to improve the information density of barcode symbol, has carried on the research work. Multidimensional barcode and container bar code become the research, exhibition and application direction. <BR> information density is an important parameter to describe the barcode symbol, that is, the number of letters that may be written in the unit length, which is usually recorded as: the number of letters/CM. The main factors that affect the density of information are the width of strip, empty structure and narrow element system. <br>128 and 93 yards are the successful attempts of people to increase their density. 128 yards city was recommended for 1981 years, and 93 yards were put into use in 1982. The symbolic density of both codes is nearly 30% higher than 39 yards. <BR> with the development of barcode technology and the increasing variety of barcode system, the standardization of bar code becomes more and more important. To this end, has developed a military standard 1189, cross 25 yards, 39 yards and Coda bar code ANSI standard Mh10.8m and so on. At the same time, some industries have started to establish industry standards to meet the needs of development. Since then, David Allire has developed 49 yards. This is a non-traditional barcode symbol, which has a higher density than the previous barcode symbol. Tede Williams (Ted Williams) GFI988 launched the 16K code, which is similar in structure to 49 yards, is a newer type of code, suitable for laser systems.



Origin: (http://www.cnblogs.com/gnielee/)


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.