marcus-s
4/26/2016 - 3:33 PM

Angular: Making a GET request

Angular: Making a GET request

var foo_app = angular.module("foo_app", []);

foo_app.controller("bar_controller", ["$scope", "$http",
  function ($scope, $http){
    $http({
      method: "GET",
      url: "api/foo/bar/",
    }).then(
      function successCallback(response){
        console.log(response);
    });
  }]);