cURL / Mailing Lists / curl-library / Single Mail

curl-library

RE: cURL-PHP PUT problem

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sat, 5 Apr 2008 23:59:56 +0200 (CEST)

On Sat, 5 Apr 2008, Mahendra Gayatri wrote:

> Thanks for the reply, but my problem stays put.

> HTTP/1.1 412 Precondition Failed

please don't top-post

The RFC2616 clearly describes this response code:

10.4.13 412 Precondition Failed

    The precondition given in one or more of the request-header fields
    evaluated to false when it was tested on the server. This response
    code allows the client to place preconditions on the current resource
    metainformation (header field data) and thus prevent the requested
    method from being applied to a resource other than the one intended.

What you see is not a libcurl problem, it is your application's problem since
you've added headers that the server deemed was enough to warrant a 412.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
Received on 2008-04-06