The following warnings occurred: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Warning [2] Undefined array key "avatartype" - Line: 783 - File: global.php PHP 8.1.27 (Linux)
|
Form make empty entries in Database - Printable Version +- Form Tools (https://forums.formtools.org) +-- Forum: Form Tools (https://forums.formtools.org/forumdisplay.php?fid=1) +--- Forum: General Discussion (https://forums.formtools.org/forumdisplay.php?fid=5) +--- Thread: Form make empty entries in Database (/showthread.php?tid=510) |
Form make empty entries in Database - mr_twin - Feb 11th, 2010 Hello, I have a problem with FormTools. When I go to the form on my website without to fill in something an went back to another site of my homepage (over backbutton from Firefox or over my pagenavigation), Formtools make an empty entry in my database. As soon as run the form, it makes an NULL entry. What goes wrong? Sorry for my bad english. I hope you can understand Thank you very much! Have a nice day! Marcel RE: Form make empty entries in Database - Ben - Feb 12th, 2010 Hi Marcel, No, I think I understand! So is your form an API form or a direct form? If it's a direct form and you're getting duplicate entries that means that the user has clicked back in their browser and clicked "OK" to the popup that says "are you sure you want to resubmit the form?" (or whatever). If it's the API then yes, it will always make a new empty, unfinalized record in the database. But this isn't so bad. What you can do is just clean out the dud data using this function ft_api_delete_unfinalized_submissions. See: http://docs.formtools.org/api/?page=ft_api_delete_unfinalized_submissions You should be able to just add that line to the top of your API form and it will only delete old dud data. Let me know how it goes! - Ben RE: Form make empty entries in Database - mr_twin - Feb 15th, 2010 Hi Ben, thanks for your hint. I use the API for our form. I add ft_api_delete_unfinalized_submissions to the top of my API form and it works great. Now it went like clockwork Great thanks That was a great help! Greetings Marcel |