我在设置外部Kohana3.1+请求的内容类型标头时遇到困难。
$r = Request::factory($this->api)
->method(Request::PUT)
->body($this->to_json())
->headers('content-type', 'application/json');请求最终由curl执行。请求类型(PUT)和请求主体( json)的CURLOPT_设置正确,但没有设置内容类型。
我是不是走错了路?
发布于 2011-03-11 16:37:10
https://stackoverflow.com/questions/5252996
复制相似问题