Hello everybody,
I've got a problem using curl to upload a file. I want to send it to a form
written with the Django Framework.
Post Request are processed correctly, with one anomaly.
This piece of code works fine
curl_setopt($process, CURLOPT_POSTFIELDS, http_build_query($data));
But if i provide only an array no data is send to the form
curl_setopt($process, CURLOPT_POSTFIELDS, $data);
I have read somewhere that curl sends formdata with enctype="form/mulitpart"
only if I provide an array not a string.
If I add "@filename" to the $data variable (string or array) it does not
send the file to the form.
Each example I have found in the internet so far did not work.
Any support or idea?
Thanks for anything!!!!
Mattes