Filehandling in CGBetterForms
Posted: Thu Feb 01, 2018 3:53 pm
I have some problems figuring out how to handle file-uploads in CGBetterForms properly. Im mostly interested in sending the form results a a predefined email-adress.
Everyting is working fine. The file is uploaded, and the email recipient gets a url for downloading the file.
But I cannot get validation to work. So there is no limit on filetype or filesize using
with validation: "Validate uploaded files".
And I cannot find a way to get the server to delete the files after a set time. Eg. 90 days. Is there any smart way to do this? I dont want the server to be filled up with old files.
Everyting is working fine. The file is uploaded, and the email recipient gets a url for downloading the file.
But I cannot get validation to work. So there is no limit on filetype or filesize using
Code: Select all
<input type="file" id="fil" class="form-control" name="fil" data-cgbf-accept="image/*,application/*pdf,application/*word*" data-cgbf-maxsize="1024">
And I cannot find a way to get the server to delete the files after a set time. Eg. 90 days. Is there any smart way to do this? I dont want the server to be filled up with old files.