How can you scan QR code using HTML5 and MVC3?
12,789
Solution 1
There is no public camera API in HTML5 as is in a web browser.
For now, you can use frameworks embedding HTML5 to native apps to do this.
An example:
ZBar QR code scanner for Phonegap
http://blog.infoentropy.com/Use_ZBar_barcode_reader_with_PhoneGap
The payload of QR code can be any text, but it is usually a HTML link.
Solution 2
On Android and iPhone you can scan from a web page this way: http://code.google.com/p/zxing/wiki/ScanningFromWebPages
It's not really scanning with HTML5 or anything, but, may be the closest you can get.
Author by
updev
Updated on June 04, 2022Comments
-
updev almost 2 years
Can anyone help or explain how QR code would work using HTML5 and MVC3?
Can it be scanned using laptop webcam or will only work on mobile sit?
-
updev about 12 yearsThanks Mikko for the reply. Can you allobrate this sentence, because i didn't get it: "no public camera API in HTML5 as it is in the web browser"? Besides allowing it to the native camera, can this be done from a laptop where it has a webcam?
-
Agustin almost 11 yearsPlease correct me if I'm wrong, but I would say getUserMedia is pretty close to a "camera API", no?
-
Mikko Ohtamaa almost 11 yearsThat's correct. Please note that the answer was written more than one year ago.
-
Trafalgar D Law over 7 years@Agustin the
getUserMedia
can be use as a searching for data after scanner a QR?. I am a project that can generate a QR so I need to scan it and find the data from my system(grid)