QR Code for Ionic

Is there a way to read QR code from mobile device, just like Barcode scanner… if its exist… how could I implement it or is there an example ?

hi

please check ng-cordova

http://ngcordova.com/docs/plugins/barcodeScanner/

2 Likes

how does QRcode works ?

hi,

what your question is about

how to read/scan qr code
or
how to generate qr code

sorry for that :smile:
how to scan QR code sir. :wink:

you have full example
in the link i sent

module.controller('BarcodeCtrl', function($scope, $cordovaBarcodeScanner) {

document.addEventListener("deviceready", function () {
 $scope.scanNow = function(){  --> add scanNow to a button using ng-click="scanNow()" 
  $cordovaBarcodeScanner
  .scan()
  .then(function(barcodeData) {
    // Success! Barcode data is here
    console.log(barcodeData); 
  }, function(error) {
    // An error occurred
  });

 }

 }, false);
});
1 Like

sorry… I thought it only read barcode… sorry for that :smile:

1 Like

Hi,

if you have an example to generate a Qr code, can you show me a code please ? I use this :
https://github.com/phonegap/phonegap-plugin-barcodescanner .

I come to the function(success) but after I don’t know how I can display the QR Code.

Thanks for any help

I use angular qrcode generator :slightly_smiling:

1 Like

I try and it’s I need to do.
Thank you very much :grin:

1 Like