访问 angular.js $http
对象的 secret 是什么?
function MyController($scope) {
$http... // not defined
}
最佳答案
你应该注入(inject)它:
function MyController($scope, $http) {
$http... // now is defined
}
关于javascript - 访问 Angular $http,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21033448/