How to use ChronoForms File Upload

peterswa62 17 Jun, 2013
I need a user to be able upload a file and then on submitting the form save the file to a directory make sure the filename is unique and put the file path and name in a database row associated with the user. Do you have to resort to PHP code to do that as I cannot see any configuration on the File Upload control?
GreyHead 17 Jun, 2013
Hi Peterswa62,

I think that the Upload Files action does most of that; which bit are you having problems with?

Bob
peterswa62 18 Jun, 2013
Thanks didn't know of the Uploads File Action I thought the settings would be on the File Upload control and wondered where they were.

It seems to cover most of what I want to be able to do apart from making sure the filename is unique as I will be uploading files to the same directory and there is a possibility that a file might write over another one because it has the same name. Can you put code in code block to check for that?
GreyHead 18 Jun, 2013
Hi peterswa62,

The default filename adds a date-time string to the file name which pretty much ensures that they will be unique.

Bob
peterswa62 18 Jun, 2013
Thanks that's all I wanted to know.
mwallace 17 Dec, 2013
In EASY FORM WIZARD > FILES UPLOADS tab, there is no field for the FILE UPLOAD PATH. But if I use FORM WIZARD, there is an extra field for the FILE UPLOAD PATH. Am I missing something in the EASY FORM WIZARD, where I can type in the FILE UPLOAD PATH?

BTW, GreyHead, nice chevron.
GreyHead 17 Dec, 2013
Hi Mwallace,

No, the Easy Wizard makes some of those choices for you to keep things easy. Switch the form to the Form Wizard if you want to over-ride the defaults. Please see this FAQ

Bob
This topic is locked and no more replies can be posted.