Easy To Use Automatic QR Code Generator

custom_qr_code_generator

Love them or hate them, plenty of people around the world use QR codes on a daily basis. Since he thinks they’re pretty great, Hackaday reader [falldeaf] thought it would be cool to put together an automatic QR code generator to be used on web sites.

Inspired by the custom QR logo embedding work done by our own [Brian Benchoff], his dynamic QR code generator allows you to do the same thing, but with far less work. The code requires that you have PHP and the GD library installed on your server, but other than that his code does the rest.

All you need to do is call up the page and pass along a URL, optional caption text, optional image overlay (to add your logo to the center of the code), as well as an optional hash code for tracking traffic sources. The page spits out a png image that can be used on its own, or embedded in a blog, which is what [falldeaf] plans on using it for.

If QR codes are your thing, be sure to grab a copy of his code, it will certainly be a handy tool to have around.

20 thoughts on “Easy To Use Automatic QR Code Generator

  1. This would probably be better done in Javascript after the page had finished loading, as having to generate and download the image on the server for every page is a little wasteful. I’d also recommend hiding it using CSS unless media=print (which is the only time it actually needs to be shown – preferably absolute positioned at the top right corner of the printed pages).

  2. I can’t stand when people put their logos or whatever in QR codes and just rely on error correction like that. The fantastic error correction of QR codes is in place to make it easier to scan and more resistant to damage. Not to put a crappy pixel leaf in the center and leave a bunch of half pixels in it.

  3. Not having a server,or renting server space I have no way of putting this effort by falldeaf to use. I suppose I could create a virtual sever on my computer, and experiment that way. Not having a smart phone to test resulting QR codes, I best leave them alone. Some people are developing unreasonable attitudes to QR codes. I have save the file, in the event I can put it to use later, thanks to falldeaf for mailing it available.

  4. Thanks for the compliments! And thanks Mike, for the nice write-up.

    @Anonymous: That’s true, it does actually degrade the error correction by putting a logo in it. But in this case, you’re taking a picture of your monitor with a phone from a distance of 1 foot. It should be pretty easy to get a good shot of it. In a situation where it’s harder, on a billboard for instance, where there may be obstructions between you and the target, your argument makes more sense. Thanks for reading anyway! :)

  5. Just to clear a few things up:

    @BG: My code uses that API already.

    @Neftaly Hernandez: I’m not generating each image on the fly, it’s all getting cached. That’s my personal server setup, though. After a tip from someone on twitter though, I’m considering turning this into a wordpress plugin that does the caching in a more stand-alone fashion.

    Thanks again for reading!

  6. I think QR codes are cool and under used. I am not sure about this form of embedding images as I haven’t tried it yet but looks interesting.

    If you are creating multiple (more than 5 or 6) QR codes for people the online method is time consuming.
    I worked out a system to manage getting people to enter data (in a google form) and then convert that into QR codes using a bash shell script.
    I’m including it here as a point of interest even if it isn’t directly related to this post:
    http://david-halliday.co.uk/wiki/doku.php?id=linux:scripts:encode_qr_codes

  7. Hi, I need to make a double qr code, that is, a smaller QR code is embedded into the original QR code, for having a double information. I saw some of them on internet, but no one explains how to create them. Do you know anything about this?

  8. Thanks on your marvelous posting! I truly enjoyed reading it,
    you’re a great author. I will make certain to bookmark
    your blog and may come back sometime soon. I want to encourage
    that you continue your great work, have a nice afternoon!

Leave a Reply to AudCancel reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.