I'm trying to write a shell script for uploading images to a php page. The php page is done and works, if I choose a file from an html form and post it, the image uploads fine.
What I would like is to be able to use curl to upload the image like the form does. My curl line looks like this:
curl http://x.x.x.x/imageput.php --data-binary "userfile=/path/image.jpg"
My php takes this and errors because it's looking to copy the file from /path/image.jpg which doesn't exist on the server, just the scripts machine. Make sence? From what I understand I can send files to the server with curl, I just don't know how.
Thanks