Open andre-kornetzky opened 6 years ago
Thanks for using Caldera Forms.
I just tested and with this code in place, and a form that has a file field, set to attach to the mailer, but not to upload. It worked as expected: the file was still on the folder.
Are you sure that this code is running? I would put it in a plugin.
Please note, this is not a support channel. If you need immediate help with your site or help troubleshooting Caldera Forms on your site, please open a support ticket at https://CalderaForms.com/support
I get the email (if enabled) - so I think the plugin works in general. The theme also works - tested by manipulating the CSS file and an echo output in the funtions.php. But if I add an echo command in the function "add_action ('caldera_forms_core_init', ...", this line will not be printed. Probably 'caldera_forms_core_init' is never called in the functions.php of a theme?
OK, with a plugin it works for me too. So I think that the following statement is wrong:
Technically you can add the custom code to your theme's functions.php, but then you will not be able to change your theme and keep these customizations.
https://calderaforms.com/doc/alternative-file-upload-directory/
Can you test it with a theme and confirm the bug?
Hello. I'm about to validate Caldera for our mission and found an error. It does not work that uploaded files are stored on the server (permanently).
I have the following environment:
the short debug line is: WordPress Version: 4.9.4PHP Version: 7.2.2MySQL Version: 5.7.21Caldera Forms Version: 1.5.9.1WP_DEBUG: 1
When I enter an entry now, most things work fine (mail is sent, database entry is created, ...). Only no file is available behind the link. For example: http://localhost:8080/wp-content/uploads/7e524d2b14b4db2883e4c8b422fa9937/pig.png
But there is no file or folder to find in uploads.
If I activate "Attach to Mailer" the file will be added to the mail. If I activate "Add to Media Library", the file is stored in the Media Library. If nothing is activated, the file is gone.
After reading the following article (https://calderaforms.com/doc/how-caldera-forms-file-attachments-uploads-work/), I created a child theme and added the lines to the functions.php.
But it did not help. There is no entry in the log file (debug.log). It just does not save the file on the server.
Side Note: I also tested Contact Form 7 and the upload works there without problems. Therefore, I do not believe that the cause of the error is the write permissions.
Thank you for your work.