Question

Is it possible to add watermark to QR code generated by google charts api using jquery or cakephp.

I appreciate any help.

Thanks.

Was it helpful?

Solution

I wouldn't watermark a QR code. Instead, I'd probably watermark the data I was encoding in the QR code in some way.

For example, if you're encoding a URL, could you, for example, change the URL from "http://example.com/foo" to "http://example.com/foo?watermark-referrer=www-yourdomain-com-whatever"? Then there's still an indication that the QR code is yours, but you don't have to risk breaking the QR image itself.

OTHER TIPS

I guess the only way to do that is saving the image generated by google charts on your server, and then add the watermark vi GD or imagemagick.

A jQuery option is to just place a watermark image on top of the one that Google Charts makes, but the original will still be available.

A PHP option is generate the QR image via a curl request, read the bitmap data in, muck with it via GD or ImageMagick, then save it somewhere and display it.

The watermark may interfere with a scanning algorithm, though, especially when read with a bad camera.

I think you should test the QR code with watermark, because there is a big chance that lots of reader won't recognize.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top