I have a web server running some PHP that checks for an image (curl -F 'imageName=@myimage') and it also checks the POST data for username=&password=.
When the PHP checks _REQUEST I cannot just do:
curl -F 'imageName=@myimage' \
'http://www.example.com/?upload=1&username=test&password=test'
I need to instead check _POST for username and password due to specs. How can I upload the image and have the username=&password= post data?
Any help appreciated!
-F. (Sorry for that.) You cannot combine them with&because-Fmakescurlsend amultipart/form-datarequest, which uses a completely different way of separating fields. You could use-dinstead, which sends the POST request asapplication/x-www-form-urlencoded, but it's absolutely unsuitable for file uploads. – u1686_grawity Jan 14 '11 at 18:50