I want to output the filename. I also want to check the length of the filename. I have tried the following which didn't work.
echo $_POST[$_FILES['file']['name']];
echo (strlen($_POST[$_FILES['file']['name']]);
I want to output the filename. I also want to check the length of the filename. I have tried the following which didn't work.
echo $_POST[$_FILES['file']['name']];
echo (strlen($_POST[$_FILES['file']['name']]);
don't use $_POST for getting the files, simply use $_FILES to get the uploaded files as
echo $_FILES['file']['name'];
echo $_FILES['file']['tmp_name'];
To get the file size use
echo $_FILES['file']['size']