error.serialization.response Code=-1016 "Request failed: unacceptable content-type: text/html" UserInfo=0x170660600 {com.alamofire.serialization.response.error.response=<NSHTTPURLResponse: 0x17043d780> { URL: http://182.92.214.199/hot/delete } { status code: 200, headers {
"Cache-Control" = "no-store, no-cache, must-revalidate, post-check=0, pre-check=0";
Connection = "keep-alive";
"Content-Encoding" = gzip;
"Content-Type" = "text/html";
Date = "Thu, 02 Apr 2015 09:43:00 GMT";
Expires = "Thu, 19 Nov 1981 08:52:00 GMT";
Pragma = "no-cache";
Server = "nginx/1.4.7";
"Transfer-Encoding" = Identity;
Vary = "Accept-Encoding";
"X-Powered-By" = "PHP/5.4.27";
} }, NSLocalizedDescription=Request failed: unacceptable content-type: text/html, NSErrorFailingURLKey=http://182.92.214.199/hot/delete}
解决方案:
manager.responseSerializer.acceptableContentTypes = [NSSet setWithObject:@"text/html"];