|
@@ -1,53 +0,0 @@
|
|
|
-<html lang="en">
|
|
|
-
|
|
|
- <head>
|
|
|
-
|
|
|
- <meta charset="utf-8">
|
|
|
- <meta name="author" lang="fr" content="Maxence Bacquet">
|
|
|
- <title>Microfolies</title>
|
|
|
- <link rel="stylesheet" type="text/css" href="css/style.css">
|
|
|
- <script type="text/javascript" src="./js/jsQRScanner/jsqrscanner.nocache.js"></script>
|
|
|
-
|
|
|
- <script type="text/javascript">
|
|
|
- function onQRCodeScanned(scannedText)
|
|
|
- {
|
|
|
- var scannedTextMemo = document.getElementById("resultScan");
|
|
|
- if(scannedTextMemo)
|
|
|
- {
|
|
|
- scannedTextMemo.value = scannedText;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- //this function will be called when JsQRScanner is ready to use
|
|
|
- function JsQRScannerReady()
|
|
|
- {
|
|
|
- //create a new scanner passing to it a callback function that will be invoked when
|
|
|
- //the scanner succesfully scan a QR code
|
|
|
- var jbScanner = new JsQRScanner(onQRCodeScanned);
|
|
|
- //reduce the size of analyzed images to increase performance on mobile devices
|
|
|
- jbScanner.setSnapImageMaxSize(300);
|
|
|
- var scannerParentElement = document.getElementById("scanner");
|
|
|
- if(scannerParentElement)
|
|
|
- {
|
|
|
- //append the jbScanner to an existing DOM element
|
|
|
- jbScanner.appendTo(scannerParentElement);
|
|
|
- }
|
|
|
- }
|
|
|
- </script>
|
|
|
-
|
|
|
- </head>
|
|
|
-
|
|
|
- <body>
|
|
|
-
|
|
|
- <h1>Scanner QRcode</h1>
|
|
|
-
|
|
|
- <div id="scanner">
|
|
|
- </div>
|
|
|
-
|
|
|
- <div>
|
|
|
- <textarea id="resultScan" readonly="yes">Result of scanning !</textarea>
|
|
|
- </div>
|
|
|
-
|
|
|
- </body>
|
|
|
-
|
|
|
-</html>
|