formtools / module-field_type_file

The File Upload Field module.
http://docs.formtools.org/modules/field_type_file/
GNU General Public License v3.0
1 stars 6 forks source link

Support multiple file uploads in a single field #1

Closed benkeen closed 5 years ago

benkeen commented 6 years ago

This'll need the module to be revised, I think. But a very reasonable request!

sf23103 commented 5 years ago

How will the file names be stored in the database when multiple files are uploaded from a single field? Just curious how this will be handled!

benkeen commented 5 years ago

Good question, I was pondering the same thing. So right now the field just stores the filename; the file folder + URL are associated with the field itself. So I was thinking of using the colon character as a delimiter to store all file upload names in the database field. A colon is an invalid character for filenames on both Mac + Windows boxes so it seems a sensible delimiter.

sf23103 commented 5 years ago

Cool, that sounds reasonable. I've got a couple of apps that display images on a page from particular submissions, so I was just thinking about how I'll handle that. I'll just have to parse multiple images out from colon delimiters. Should be easy enough, and the trouble well worth the ability to have multiple uploads in one a single field.

benkeen commented 5 years ago

This is now working. Should get it out today or tomorrow.