I want to know how to upload a file using cURL or anything else in PHP. I searched google many times, but there were no results.
I have this code to get the file and upload it
the code:
echo"".$_FILES['userfile'].""; $uploaddir = './'; $uploadfile = $uploaddir . basename($_FILES['userfile']['name']); if ( isset($_FILES["userfile"]) ) { echo '<p><font color="#00FF00" size="7">Uploaded</font></p>'; if (move_uploaded_file ($_FILES["userfile"]["tmp_name"], $uploadfile)) echo $uploadfile; else echo '<p><font color="#FF0000" size="7">Failed</font></p>'; }
I want the code to send the file to the recipient file.
php upload curl
Hadidi44 Mar 04 2018-12-13T00: 00Z
source share