Created
April 26, 2016 15:33
-
-
Save marcusshepp/204e11fb04194544f175bd256a58891f to your computer and use it in GitHub Desktop.
Angular: Making a GET request
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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); | |
}); | |
}]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment