uploading & working with Multiple files on POST (view function in page type controller)
Permalink
Trying to work with multiple files selected on a front end form, using my own theme, which is using the view function in a page type controller of a page using this:
The input field on my page looks like this:
Currently returns NULL on submit, what am I doing wrong??
I am aware I can get a single file in like this:
I presume a foreach on the multiple files array would be ok, though how would I add to a set?
$images = $_POST['images[]'];
The input field on my page looks like this:
<input type="file" multiple value="" name="images[]" id="images" />
Currently returns NULL on submit, what am I doing wrong??
I am aware I can get a single file in like this:
Loader::library("file/importer"); $fi = new FileImporter(); $newFile = $fi->import($pathToFile, $nameOfFile, $fileObject);
I presume a foreach on the multiple files array would be ok, though how would I add to a set?