I am trying to: create application form which create an account with Applicant role for each user . when I login using the admin I can upload file and set the birth date but when I login using applicant accounts I cannot . the error is "There was an error uploading the file " I checked the permissions of Applicant role everything was fine . then I deleted the applicant role and I recreated it works fine one day then the same problem comes again . what cause the problem ??
Hello,
Are we talking about a Toolset form for creating post?
How do you setup the permissions of Applicant role? can you take a screenshot for it?
Please check these in your website:
1) Deactivate other plugins and switch to wordpress default theme 2017, and test again
2) Enable PHP debug mode, copy and paste the debug logs here, we need to know if there is any PHP error in your website:
https://toolset.com/documentation/programmer-reference/debugging-sites-built-with-toolset/
PHP Debugging
To enable PHP debugging in WordPress, edit your wp-config.php file and add the following:
PHP Debugging in WP
ini_set('log_errors',TRUE);
ini_set('error_reporting', E_ALL);
ini_set('error_log', dirname(__FILE__) . '/error_log.txt');
Also check if there is any JS error when you submit the form.
3) If the problem still persists, please provide provide a database dump file (ZIP file) of your website in below "private detail box", I need to duplicate same problem and debug it in my localhost, thanks.
Thanks for the details, I can download the files, where and how can I see the problem you mentioned above:
There was an error uploading the file
Please point out the problem page URL and form URL, thanks
I have tried these in my localhost with your database dump file:
Login as FOS Applicant user "iman.alfakhari", test the Toolset form "test" in front-end hidden link, it works fine, there isn't the similar problem as you mentioned above, the custom date field and file fields are saved correctly, so it should be a compatibility problem or server problem, please try as I mentioned above:
Deactivate other plugins and switch to wordpress default theme 2017, and test again
Hi Luo Yang,
This is the error message I receive when I see from the Google chrome console.
frontend.js?ver=2.0:364 Toolset Forms: Error parsing callback data for `check_post_id`
(anonymous) @ frontend.js?ver=2.0:364
util.js:248 Google Maps API warning: RetiredVersion hidden link
UC.j @ util.js:248
(index):1 Uncaught SyntaxError: Unexpected token < in JSON at position 0
at JSON.parse (<anonymous>)
at Function.n.parseJSON (jquery.js?ver=1.12.4:4)
at Function.a.parseJSON (jquery-migrate.min.js?ver=1.4.1:2)
at Object.success (date.js?ver=0.1.2:97)
at i (jquery.js?ver=1.12.4:2)
at Object.fireWith [as resolveWith] (jquery.js?ver=1.12.4:2)
at y (jquery.js?ver=1.12.4:4)
at XMLHttpRequest.c (jquery.js?ver=1.12.4:4)
Is it related to the upload error? I am using Avada Charity theme. Do you think my theme makes problem?
Thanks
I am not sure if it is the problem of your theme, as I mentioned above, you can check it simply by this:
Deactivate other plugins and switch to wordpress default theme 2017, and test again
If the problem is fixed, then it should be a compatibility, you can activate other plugins one by one, try to locate the problem plugin or theme
Hi,
I tried deactivating all the plugins and set back to 2017 and 2015 themes. it works very well. Problem comes when AVADA theme is activated. Even I deactivated the Fusion Core and Fusion builder. The upload and date field doesn't work.
Have you come across similar issue?
Thanks
So it should be a compatibility problem, please provide a copy of your website in below private detail box:
https://toolset.com/faq/provide-supporters-copy-site/
for sharing purposes, you could use services like DropBox and Google Drive among others.
I need to debug it in my localhost, thanks
Your website duplicator package is too big to download, please confirm this:
1) This problem occurs when there is only Avada theme + Toolset plugins
2) If there isn't any other compatibility problem, please provide the copy of Avada theme only, you can update your private message here:
https://toolset.com/forums/topic/date-and-upload-file-is-not-working-for-non-admin-accounts/#post-919717
Hi,
Yes. When I activate AVADA, it creates problem. With other themes it is fine. I disabled all the plugins except Toolset. If the file is too big to download, i can give my website credentials.
Thanks
As I mentioned above, I need to duplicate the same problem and debug it in my localhost, the website credentials won't help much, I am downloading the file you provided, it will take few hours, and since it is a compatibility problem, there isn't any ETA for the fix, I will update this thread if there is anything found
I have tried the Avada theme + your database dump file + the latest version of Toolset plugins, it works fine, I can login as FOS Applicant user "iman.alfakhari", and submit the Toolset form without the error you mentioned above:
hidden link
So it should be a server/other compatibility problem problem, have you got any PHP debug logs after you submit the Toolset form?
Enable PHP debug mode, copy and paste the debug logs here, we need to know if there is any PHP error in your website:
https://toolset.com/documentation/programmer-reference/debugging-sites-built-with-toolset/
PHP Debugging
To enable PHP debugging in WordPress, edit your wp-config.php file and add the following:
PHP Debugging in WP
ini_set('log_errors',TRUE);
ini_set('error_reporting', E_ALL);
ini_set('error_log', dirname(__FILE__) . '/error_log.txt');
the problem solved .. it was in a code that I add in function.php file