AngularJS $http.post() to another port at the same machine AngularJS $http.post() to another port at the same machine nginx nginx

AngularJS $http.post() to another port at the same machine


You should specify the protocol scheme (http, https, ...) in the URL:

$http.post('http://localhost:7001/testApp/user/login', { username: username, password: password })        .success(function (response) {            callback(response);});