XMNetworking icon indicating copy to clipboard operation
XMNetworking copied to clipboard

能修改默认支持的Content-type类型吗

Open rongxianyu opened this issue 8 years ago • 4 comments

默认不支持content-type: text/html或者text/plain,能在配置里改吗?还是只能修改源文件?

rongxianyu avatar May 19 '17 08:05 rongxianyu

同问,在request.headers中设置好像无效

championfu avatar Jun 01 '17 01:06 championfu

试试 request.headers = @{@"Content-Type": @"你的自定义 Content-Type"};

kangzubin avatar Jun 01 '17 04:06 kangzubin

修改多个content-type 如何设置???

Blavtes avatar Nov 01 '17 07:11 Blavtes

[[XMEngine sharedEngine].sessionManager.requestSerializer setValue:@"修改成啥都可以" forHttpHeaderField:@"Content-Type"];

westke avatar Jan 12 '18 05:01 westke