1

I'm new to Hybrid application dev, using Appgyver Supersonic

I'm trying to make a http request for user to login, below is the code:

$http.post({
url: 'http://www.somesite.com/check.login.php',
data: $scope.logd,
crossDomain: true,
cache: false,
headers : {'Content-Type': 'application/x-www-form-urlencoded'}
}).success(function(data, status, headers, config) {
// do something
}).error(function (data, status, headers, config) {
// do something
});

In response I get data as:

<html><head><meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0'></head><body><h1>404 Not Found</h1>/app/login/[object Object] was not found.</body></html>

response status is 200,

I'm also new to angularjs, Can you please let me know what could be the issue here and the possible actions that can be taken?

ashirwadrk
  • 126
  • 4
  • Are you getting anything in the javascript console? How are you debugging? – area28 Oct 16 '15 at 16:15
  • Hi @area28 , tried to user the browser's console. It fills up with angularjs errors! Like - Error: [$interpolate:interr]. can't see any post's happening.. – ashirwadrk Oct 19 '15 at 04:33
  • It worked, instead of $http.post({..}), I used the method: "POST" parameter.. Thanks. – ashirwadrk Oct 19 '15 at 05:16

0 Answers0