Actually I want to a call an php url with jQuery mobile ajax call in android phonegap. The possible outcomes of the url are
- if successs then -- valid
- if fails the -- Code:201
I am using this code but it is not working help me.
var request = $.ajax({
url : "http://URL.com/api/validate.php?user=myUser&password=myPassword",
type : "GET"
});
request.done(function(msg) {
$("#notification").text(request.val());
});
request.fail(function(jqXHR, textStatus) {
alert("Request failed: " + textStatus);
});