cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: cURL behavior on 303 does not seem to be what is documented/advertised?

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Wed, 16 Jan 2013 09:13:15 +0100 (CET)

On Tue, 15 Jan 2013, Yves Arrouye wrote:

> $ curl -LsS --data-binary 'foo=bar&lol=3' -X POST -H 'Host:
> paymentwallet.int-maui.karmalab.net' -k
> https://paymentwallet.int-maui.karmalab.net v

...

> [[[[LOOK HERE]]]]
> * Disables POST, goes with GET

...

>> POST / HTTP/1.0

This is because you've explicitly told curl with -X that you want a POST to be
used. Why would you do that if you don't want that?

If you want to let curl do the "right" thing, just remove "-X POST" from your
command line. Oh, and you should probably also consider to remove your Host:
thing that seems superfluous as well.

-- 
  / daniel.haxx.se

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2013-01-16