Hi, A web developer told me that there are other ways to upload a file in PHP, other than using the $_FILES array. I am puzzled. Is there any way to upload files without using $_FILES array in PHP? Thank you.
LoL No. He is on another forum. I have asked him the details but no answer yet. So I guess, there are no alternatives within PHP, as I suspected. Thanks all for answers.
Well, you can use $HTTP_FILES_VARS instead of $_FILES. Lol, just kidding. I don't know how to upload file without $_FILES.
If you want to upload from a form with http post there is no other way.You can use php ftp functions for uploading if you have access to the file location and location to upload.
Okay, the person (web developer) has confirmed that he was confused. Thanks for answering all Nice workaround there xrvel and osol Thanks
$HTTP_FILES_VARS is a deprecated superglobal which is the equivalent of $_FILES for older PHP versions, so if your using the latest PHP you'd be using $_FILES and using $HTTP_FILES_VARS would trigger an error. Furthermore using the ftp_* functions will still require you to use the $_FILES array as you'll need to retrieve the uploaded file for it to be transfered to the ftp.