Improve this Doc View Source $httpProvider
Use $httpProvider
to change the default behavior of the $http service.
Properties
-
defaults
Object containing default values for all $http requests.
-
defaults.xsrfCookieName
- {string} - Name of cookie containing the XSRF token. Defaults value is'XSRF-TOKEN'
. -
defaults.xsrfHeaderName
- {string} - Name of HTTP header to populate with the XSRF token. Defaults value is'X-XSRF-TOKEN'
. -
defaults.headers
- {Object} - Default headers for all $http requests. Refer to $http for documentation on setting default headers.defaults.headers.common
defaults.headers.post
defaults.headers.put
defaults.headers.patch
-
-
interceptors
Array containing service factories for all synchronous or asynchronous $http pre-processing of request or postprocessing of responses.
These service factories are ordered by request, i.e. they are applied in the same order as the array, on request, but reverse order, on response.
© 2010–2017 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://code.angularjs.org/1.2.32/docs/api/ng/provider/$httpProvider