I have tried:
curl -v --http1.0 --data "mac=00:00:00" -F "userfile=@/tmp/02-02-02-02-02-22" http://url_address/getfile.php
but it fails with the following message:
Warning: You can only select one HTTP request!
How can I send a mix of data and file by curl
? Is it possible or not?
Thank you
Read up on how -F actually works! You can add any number of data parts and file parts in a multipart formpost that -F
makes. -d
however makes a "standard" clean post and you cannot mix -d
with -F
.
You need to first figure out which kind of post you want, then you pick either -d
or -F
depending on your answer.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With