2

I am working on PHP and i am stuck where i want to get folder/directory name which i select in file upload control.

It is working fine, but i am not able to get folder name using jQuery.

 <input type="file" name="files[]" id="audios" multiple="" directory="" webkitdirectory="" mozdirectory="">

My code is like above, i just want to get folder name instead of all file names included in that folder.

Any help will be great, Thanks in advance :)

KMG
  • 104
  • 7
  • 1
    Possible duplicate of: https://stackoverflow.com/a/15201258/5503275 – DsRaj Jun 07 '18 at 06:08
  • Not a duplicate. The `webkitdirectory` attribute is meant to include relative paths of the uploaded files. They are visible in the Firefox request inspector but removed on the PHP side. I'll probably report a bug in PHP. I think it's a case of "we, PHP, take away all your sorrows (and features)". – ygoe Dec 29 '18 at 22:41

0 Answers0