Reading barcode from webcam in PHP web application
Solution 1
Not with PHP, seeing as it is server side. But, you could accomplish this with java, javascript, or some other client side languages.
javascript (jQuery) webcam plugin
http://www.xarg.org/project/jquery-webcam-plugin/
EDIT -- how this would be done is to take the picture with javascript, and then send it back to the server to decode by PHP.
http://www.inliteresearch.com/homepage/support/kb_programming.html
Solution 2
I happened to come across a project where someone actually accomplished this in a pretty nice way using Javascript:
https://serratus.github.io/quaggaJS/
It only handles a few types of barcodes, but it may be a good starting point if you need the others. You can most likely have Javascript post these back to PHP using AJAX or have them update a form field to be submitted.
Tural Ali
I'm a software architect with 10+ year of experience in various fields.
Updated on April 17, 2020Comments
-
Tural Ali about 4 years
Want to add following feature to my web application: To decode barcodes generated by this script . with webcam and use values in PHP web application.
Is that possible? if yes how?