Skip to content
Advertisement

Tag: multifile-uploader

Renaming files with random string after upload and storing the name in array

I’m trying to process multiple files upload with foreach then rename the files with random string and store the file names in an array, here’s my current code: I can’t find where the problem is, should I use foreach for every generated file name then use move_uploaded_file inside the foreach? Answer You are completely wrong. You have initialized $_FILES[‘files’][‘name’] in

Advertisement