in controller
def files = request.getFiles("userFiles[]")
for (def file:files ){
//logic for saving file in you storage
}
in GSP
<g:form enctype='multipart/form-data' controller="contacts" action="addEvent" class="form-horizontal" role="form">
<input type='file' name='userFiles[]' multiple />
<input type="submit" class="btn btn-primary" value="Save Event">
</g:form>
If any confusions let me know. Email me at aadityabhatta@gmail.com
def files = request.getFiles("userFiles[]")
for (def file:files ){
//logic for saving file in you storage
}
in GSP
<g:form enctype='multipart/form-data' controller="contacts" action="addEvent" class="form-horizontal" role="form">
<input type='file' name='userFiles[]' multiple />
<input type="submit" class="btn btn-primary" value="Save Event">
</g:form>
If any confusions let me know. Email me at aadityabhatta@gmail.com