Back

如何在angular中使用$http.put, $http.post

发布时间: 2013-07-25 09:18:00

refer to: http://victorblog.com/2012/12/20/make-angularjs-http-service-behave-like-jquery-ajax/

http://stackoverflow.com/questions/11442632/how-can-i-make-angular-js-post-data-as-form-data-instead-of-a-request-payload

$http({
    method: 'POST',
    url: url,
    data: $.param({fkey: "key"}),
    headers: {'Content-Type': 'application/x-www-form-urlencoded'}
})

Back