cURL / Mailing Lists / curl-library / Single Mail

curl-library

Does libcurl POST to the current location, instead of the set URL?

From: Matthias B. <matthiasb_at_zenbe.com>
Date: Wed, 24 Jun 2009 19:02:03 +0200

Hello,
today i recognized something wondrous in libcurl.

After I created the curl-Resource, I set curlopt_url, curlopt_post,
curlopt_followlocation, curlopt_returntransfer, and curlopt_postfields.

After the first execution, the script go in a for-loop. In this loop the
curlopt_postfields gets changed, and curl gets executed again. But: It
doesn't POST to the URL which was set before - it POST to the current
Location - so I need to set the URL everytime.

Why is that behavior? Is that documented?
Received on 2009-06-24