On March 4, 2012 In Coding with , , tags

Simpler QR Code with QRserver

We were trying to add QR code for our demo links on mobile templates. It was really hard to make QR code each and every article and add them to the pages. So, we started to look for alternatives something which reduces our work.

Easy QR Code by passing parameter

We were thinking of a service like lorempixel which generates image based on url.Then we found qrserver which generates qr code based on url.

We just have pass the url or text along with api url.


By replacing url-or-text with our domain url or text(i.e mobifreaks.com in our case). will create a qr code.

<img src="http://api.qrserver.com/v1/create-qr-code/?size=500x500&data=http://mobifreaks.com" alt="Mobifreaks QR Code"/>

Mobifreaks QR Code

Thats it we have done it.

WordPress Implementation

Add following code in your wordpress loop. then we will get a qr code for every image

<img src="http://api.qrserver.com/v1/create-qr-code/?size=500x500&data="<?php the_permalink(); ?>" alt="QR Code for <?php the_title(); ?>"/>

We even customize the size of the generated qr by adjusting the pixels in size. Make sure the size is a square

Comments are closed.