美文网首页
angularJS $http服务

angularJS $http服务

作者: 德德de_前端攻城狮 | 来源:发表于2017-10-22 22:27 被阅读0次

    //创建一个应用程序

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

    //创建控制器

    app.controller("myController",["$scope","$http",function($scope,$http){

    $http.get("url").then(function successCallback(response){

    },function errorCallback(response){

    })

    }])

    相关文章

      网友评论

          本文标题:angularJS $http服务

          本文链接:https://www.haomeiwen.com/subject/fpinuxtx.html