I have a form with several
input type=\"file\"
tags. How can I know on the server side amount of files uploaded by the user. He can upload
You can use the count or sizeof on $_FILES array that contains uploaded file info:
count
sizeof
$_FILES
echo count($_FILES);
You can do this:
$counter = 0; foreach($_FILES as $value){ if (strlen($value['name'])){ $counter++; } } echo $counter; // get files count