我正在设置CURLOPT_CUSTOMREQUEST => 'PUT',并在我的localhost服务器中按预期工作。但在我的网络服务器中,我收到以下消息:
Method Not Implemented
GET to /web-services/index.php/attendance/user not supported.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
答案 0 :(得分:0)
我发现了错误。我正在使用CURLOPT_CUSTOMREQUEST => ' PUT&#39 ;.现在我只使用curl_setopt($ ch,CURLOPT_HTTPHEADER,数组(' X-HTTP-Method-Override:PUT'));.