I am doing a simple post with parameters to a php page. It works great with IOS, but on android php cannot access the post variables (if android is even sending any). Can anyone see what might be wrong in this code? Thank you for any help...
Titanium Code:
var url = 'path to php page'; var params = { ActionType : "Approve" }; var xhr = Ti.Network.createHTTPClient(); xhr.open("POST", url); xhr.onload = function() { alert(this.responseText); }; xhr.onerror = function(e) { var error_msg = Ti.API.error(e.error); alert(error_msg); }; xhr.send(params);PHP Code:
<?php echo $_POST["ActionType"]; ?>