Multiple file upload in php

前端 未结 14 1626
轮回少年
轮回少年 2020-11-21 11:32

I want to upload multiple files and store them in a folder and get the path and store it in the database... Any good example you looked for doing multiple file upload...

14条回答
  •  渐次进展
    2020-11-21 12:17

    It's not that different from uploading one file - $_FILES is an array containing any and all uploaded files.

    There's a chapter in the PHP manual: Uploading multiple files

    If you want to enable multiple file uploads with easy selection on the user's end (selecting multiple files at once instead of filling in upload fields) take a look at SWFUpload. It works differently from a normal file upload form and requires Flash to work, though. SWFUpload was obsoleted along with Flash. Check the other, newer answers for the now-correct approach.

提交回复
热议问题