Forums

file upload: no success - no error!?

ritanok 06 May, 2015
Hi,
i created a form with an optional upload field. if users chose a file, it will be mailed sucessfully and the thank you message will be displayed. if users chose a file-type whitch is not allowed, a error message will be displayed. so far: no problem. but: if users chose no file, and submit the form, there is no message dispayed, no thank you message and no error, and no e-mail will be mailed.
has anybody an idea?
GreyHead 06 May, 2015
Hi ritanok,

It sounds as though there is some kind of error when there is not upload. Is it required? How do you have the upload files action set up?

Please drag a Debugger action into the On Submit event, then submit the form without a file selection and post the debug results here.

Note: if you are using the Easy Wizard you can turn on Debug on the Others tab in CFv4 or the Setup tab in CFv5.

Bob
ritanok 06 May, 2015
Hi, thanks for your answhere. The Upload is not requiered but works perfectly if a file is chosen. The problem shows up if the user does not choose a file.

the debugger action dowesn't work too!! i put it in the on success event AND in the on fail event but no debugger will be shown!!

argh
GreyHead 06 May, 2015
Hi ritanok,

It sounds as though something is wrong with the Upload Files settings. Please take a Form Backup using the icon in the Forms Manager and post it here (as a zipped file) or PM or email it to me and I'll take a closer look.

Bob
ritanok 06 May, 2015
hi, thank you very much! here is the backup file...
GreyHead 06 May, 2015
Hi ritanok,

The problem is that you have the Email action in the On Success event of the Upload Files, If there are no files to upload that event doesn't run.

Please move (or delete and rebuild) the Email action in the main On Submit event.

Actually, you have the Files Upload action in the On Success event of the Check Captcha too. That will work but doesn't need to be like that.

I recommend that you only use the On Success events when you **have** to, for normal actions put them after the 'check action'. So I would build your form like this:
On submit

+ Check Captcha
++ On success - empty
++ On fail
+++ Event Loop

+ Files Upload
++ On success - empty
++ On Fail
+++ Display Message (or you can set this in the Files Upload action)
+++ Event Loop

+ Email
+ Display Message
Apologies for the odd formatting, I think ChronoForms is trying to work out what programming language that might be.

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