I've got a wcf Service which has a method which send its output in jsonformat. The service is hosted in an https-Environment.
i'm calling it with angularjs-resource:
var hrdemo = angular.module('hrdemo', ["ngResource"]);
hrdemo.controller('HrDemoCtrl', function ($scope, hrdbservice) {
$scope.items = hrdbservice.get({ 'Id': 1 });
var a = $scope.items.length;
});
hrdemo.factory('hrdbservice', function ($resource) {
return $resource('http://hrservice/HrService.svc/:Id', { Id: "@Id" }, { get: { method: 'JSONP' } });
});
Angularjs runs in an ASP.Net-Web Application. When calling the Service I get something like an xhr-problem.
1) How can i authenticate with my Windows authentication over angularjs 2) What can I do to fix the xhr-problem?