Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Creating QR Codes with ColdFusion

Is there any way with pure ColdFusion/cfscript to produce a QR code, without relying on external APIs or JavaScript?

like image 522
Computerman1597 Avatar asked Apr 07 '12 22:04

Computerman1597


People also ask

How do I generate a QR code?

In Chrome on Android, browse as usual to a web page, tap the three-dot menu | Share… | QR Code, then optionally tap Download to save the code to your system for later use (Figure B). On Android, tap the three-dot menu, Share, then QR Code to generate a code for a page.

Can I design my own QR code?

Yes, you can create a QR Code the regular way and make it circular through the templates available on the QR Code platform. Essentially the square QR Code has some extra design bits all around it to make it a circular QR Code.

Can you generate QR codes for free?

QRCode Monkey is one of the most popular free online qr code generators with millions of already created QR codes. The high resolution of the QR codes and the powerful design options make it one of the best free QR code generators on the web that can be used for commercial and print purposes.


2 Answers

No. ColdFusion cannot generate bar codes by itself. You need a separate tool or library. It is easy enough to install a java library, like ZXing. Then generate the images from CF. Alternately, you could do a <cfhttp> call to an external server that generates the bar code image for you, or basically do the same thing with javascript. You would not need to install anything for the latter two (2) options. But they still rely on an external resource.

Bottom line you need something more than just ColdFusion. What is the reason you cannot use either an external API or javascript? Because without either of those, you are probably out of luck.

Edit based on comments:

If the only restriction is the images must generated locally, then you can use ZXing as described in the link above -OR- any of the other components/libraries mentioned in the other responses, like Joe's suggestion which uses iText (though also based on ZXing).

like image 175
Leigh Avatar answered Oct 16 '22 04:10

Leigh


Some other external APIs

http://cfbarbecue.riaforge.org/

http://zanstra.com/my/Barcode.html?barcode=3PTSP8827A231

like image 2
JS Mitrah Avatar answered Oct 16 '22 04:10

JS Mitrah