cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: when redirect POST is changed to GET even with curl_easy_setopt(m_curl, CURLOPT_POSTREDIR, CURL_REDIR_POST_ALL)

From: David Ding <davidding2010_at_yahoo.com>
Date: Tue, 14 Apr 2009 08:59:52 -0700 (PDT)

Sorry for forgetting to mention that.
The HTTP response code is 302. We are using curl-7.19.4. How can we keep POST in case of redirect (302)?

Thanks a lot for your help.

--- On Tue, 4/14/09, Daniel Stenberg <daniel_at_haxx.se> wrote:

From: Daniel Stenberg <daniel_at_haxx.se>
Subject: Re: when redirect POST is changed to GET even with curl_easy_setopt(m_curl, CURLOPT_POSTREDIR, CURL_REDIR_POST_ALL)
To: "libcurl development" <curl-library_at_cool.haxx.se>
Date: Tuesday, April 14, 2009, 3:26 AM

On Tue, 14 Apr 2009, David Ding wrote:

> We have a application using libcurl to POST message. Whenever there is redirect, POST is changed to GET even with: curl_easy_setopt(m_curl, CURLOPT_POSTREDIR, CURL_REDIR_POST_ALL).
>
> Any idea what might be wrong?

Why is this a "wrong" at all? It depends on the HTTP response code (and your libcurl version of course).

-- 
 / daniel.haxx.se
      
Received on 2009-04-14