angular.js - Do the $http method and $httpProvider in angularjs have the same meaning?
天蓬老师
天蓬老师 2017-05-15 17:03:46
0
2
562

Do the $http method and $httpProvider in angularjs have the same meaning?
When I read a book, it was said that $http method is used to interact with the server, but $httpProvider is used. Is this a concept?

天蓬老师
天蓬老师

欢迎选择我的课程,让我们一起见证您的进步~~

reply all(2)
左手右手慢动作

Use $httpProvider to change the default behavior of the $http service.

$httpProvider is used to set the configuration of $http requests, such as disabling cache globally, adding headers, etc.

https://docs.angularjs.org/api/ng/provider/$httpProvider

淡淡烟草味

Configure $http, that is, you need to use $httpProvider in the config function

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template