Good day, I am creating a scanning function with Intel XDK with code as below:
$(document).on("click", "#scan", function(evt)
{
document.addEventListener("deviceready", onDeviceReady, false);
function onDeviceReady()
{
intel.xdk.device.scanBarcode();
}
//this event is fired when scanning is completed
document.addEventListener("intel.xdk.device.barcode.scan",function(evt){
if (evt.success == true) {
//successful scan
var quantity = evt.codedata;
alert(evt.codedata);
}
else
{
//failed scan
alert("Please try again");
}
},false);
});
On button press on device the scan is initiated and performs perfectly. What I now need to do is to pass the result to a PHP server side script. Please help me with an example of how to do this. regards