Gargron / fileupload

PHP FileUpload library that supports chunked uploads
MIT License
460 stars 87 forks source link

Store the original file name in File class #66

Closed fansanelli closed 6 years ago

fansanelli commented 6 years ago

I could implement the feature in subject, but before I'd like to hear some feedback... I'm using the random name generator, but I still need the original file name. To workaround the lack of this feature I am looping files array returned by processAll() method while reading the value from the global one: $_FILES['foo']['name'][$i]. What do you think?

adelowo commented 6 years ago

That is totally fine... Do you want to do this. You can just expose a method like getClientOriginalName or something .. Thanks for #65 anyways

fansanelli commented 6 years ago

Welcome! Now you have pull request... BTW, unrelated, it would be worth to mention the requirement of PHP extension fileinfo (and fileupload = On?) somewhere in readme. I had to dig to make everything working on hosting that had it disabled by default.

adelowo commented 6 years ago

Closed by #67