jeromeetienne / jquery-qrcode

qrcode generation standalone (doesn't depend on external services)
http://blog.jetienne.com/blog/2011/04/07/jquery-qrcode/
MIT License
4.84k stars 2.51k forks source link

Option website is not working when text field setted from variable #104

Closed androardiyanto closed 6 years ago

androardiyanto commented 6 years ago

I working with API and i got a link (in string form) from my JSON data. For example : { "msg": "Success Get Link", "downloadLinks": [ { "os": "android", "linkDownload": "http:/example.com/" }, { "os": "ios", "linkDownload": "http:/example2.com/" } ] }


in jQuery : var androidLink = downloadLinks[0].linkDownload; [result of console log androidLink is http:/example.com/]

$('#qrcodeAndroid').qrcode({width:200,height:200,text:androidLink});

QRCode is succesfully generated in this case, but when i try to get the value of QRCode, it returns Text not Website. Website is return type that i expect, so when User succesfully read the QRCode, it will redirected on that link, without copying the text and open it on the browser.

Can you help me ?

Sorry for my bad english. Thanks